Effacer les filtres
Effacer les filtres

cwt関数の結果から​、振幅の最大値を抽出​する方法を教えて下さ​い。

3 vues (au cours des 30 derniers jours)
勝也 秋元
勝也 秋元 le 25 Août 2022
Commenté : 勝也 秋元 le 29 Août 2022
<実施したい内容>
cwt関数の結果に対し、探索する領域(時間、周波数)を設定し、その範囲で振幅最大値を抽出する。
振幅最大値と時間、周波数をアウトプットにする。
添付の例)
探索区間:時間:1~2sec、周波数:4Hz以上
アウトプット(時間、周波数、最大振幅):(1.22、14.32、12.1075)

Réponses (1)

takemoto
takemoto le 29 Août 2022
load mtlb
[wt,f] = cwt(mtlb,Fs);
t = 0 : 1/Fs : numel(mtlb)/Fs - 1/Fs;
tidx = 100:2000; % ROI (time)
fidx = (20:40)'; % ROI (freq)
wtROI = wt(fidx,tidx); % ROI
fROI = f(fidx);
tROI = t(tidx);
[maxwt,idx] = max(abs(wtROI(:)));
[ii, jj] = ind2sub(size(wtROI), idx);
surf(tROI,fROI,abs(wtROI).^2), view(0,90)
shading interp, hold on
plot3(tROI(jj),fROI(ii),maxwt,'ro')
text(tROI(jj)+0.01,fROI(ii),maxwt, ...
{['time: ',num2str(tROI(jj))], ...
['freq: ',num2str(fROI(ii))], ...
['mag: ',num2str(maxwt)]})
hold off
cwt関数は、出力引数を与えることで、変換結果を獲得できますので、max関数等で最大値を抽出してはいかがでしょうか?
  1 commentaire
勝也 秋元
勝也 秋元 le 29 Août 2022
ありがとうございます。
内容理解できました。

Connectez-vous pour commenter.

Catégories

En savoir plus sur 連続ウェーブレット変換 dans Help Center et File Exchange

Tags

Produits


Version

R2021a

Community Treasure Hunt

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

Start Hunting!