hi guys
i have a pcg signal
and i want to using SHANNON ENERGY ENVELOPE for it
but i didnt find the code for it, in 'envelope' documentation there is only peak,rms and analytic function
is there any way to use the shannon energy envelope ?
shannon.PNG
thank you so much

 채택된 답변

Star Strider
Star Strider 2019년 1월 17일

1 개 추천

Shannon energy is defined as , so use an anonymous function such as:
ShannonEnergy = @(x) x.^2 .* log(x.^2);
and then take the peak envelope.
That is what I would do.

댓글 수: 5

Hi thanks for the response :)
sorry can you explain it more detail to me?
how can i take the ShannonEnergy to the peak envelope?
this is the code for peak envelope right? how can i insert the ShannonEnergy?
envelope(data,10,'peak')
Thank you very much!
My pleasure.
Now that I have your data, this appears to be the best option:
ShannonEnergy = @(x) x.^2 .* log(x.^2);
D = load('matlab.mat');
data = D.data;
Fs = D.fs;
t = linspace(0, 1, numel(data))/Fs;
SEdata = ShannonEnergy(data - mean(data));
SEenv = envelope(-SEdata, 100, 'peak');
figure
plot(t, data, '-b')
hold on
% plot(t, SEdata, '-g')
plot(t, SEenv, '-r', 'LineWidth',1)
hold off
Experiment with the various parameters of the envelope function to get the result you want.
Mr noobys
Mr noobys 2019년 1월 17일
Thank you so much !
thats solve my problem :D
Star Strider
Star Strider 2019년 1월 17일
As always, my pleasure!
cedric Adomaya
cedric Adomaya 2019년 12월 23일
help me with matlab.mat in this code

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Logical에 대해 자세히 알아보기

태그

질문:

2019년 1월 17일

댓글:

2019년 12월 23일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by