getting a binary image from a spectrogram image that shows frequency only above certain amplitude (in percent).
2 次查看(过去 30 天)
显示 更早的评论
Here is what I have done so far.
[W,fs]=wavread(FileName); %this reads a wave file
[~,~,~,P]=spectrogram(W(:,end),tres,tres/2,fres,fs); %tres is time resolution and %fres is frequency resolution.
I=flipud(-log(P)); %here 'I' gives the spectrogram image in a matrix.
imshow(I,[]); %this line will display the image.
now say I want only the top 10% of the amplitude in binary image what would be the efficient way to do it? Please look into my code. I think I calculate my spectrogram image slightly different.
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Time-Frequency Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!