I am trying to get an envelope for a spectrum I measured.
I have used the hilbert
function in MATLAB which works for a dummy function I wrote,
but it does not give the correct result for my spectrum. (I got back the exact same curve).
I am thinking the oscillation of my spectrum is too fast but not too sure on this.
Hope someone can tell me what is wrong here.
A=xlsread('test.xls');
y=A(:,2);
h1=imag(hilbert(y));
E=sqrt(y.^2+h1.^2);