How can I apply filer for three signal using matlab

1 回表示 (過去 30 日間)
C PRASAD
C PRASAD 2022 年 8 月 4 日
回答済み: Star Strider 2022 年 8 月 4 日
[tm,signal1,Fs,labels]=rdmat('emg_healthy44m');
[tm,signal2,Fs,labels]=rdmat('emg_myopathy57m');
[tm,signal3,Fs,labels]=rdmat('emg_neuropathy62m');
I haver read three signals .Now I would like to apply filetring on the tree signals at a time using for Loop

回答 (1 件)

Star Strider
Star Strider 2022 年 8 月 4 日
If they all have the same sampling frequency and are the same lengths and the same filtering requirements, concatenate them as column vectors and filter them at the same time using filtfilt or bandpass (for example) or its friends:
signals = [signal1(:) signal2(:) signal3(:)];
signals_filt = bandpass(signals, [f_low f_high], Fs);
simialrly:
signals_filt = filtfilt(sos,g,signals);
No loops are necessary.
If they are not the same lengths or have different filters or other characteristics, then it will be necessary to ‘brute force’ the filtering:
signal1_filt = bandpass(signal1, [f_low1 f_high1], Fs1);
signal2_filt = bandpass(signal2, [f_low2 f_high2], Fs2);
signal3_filt = bandpass(signal3, [f_low3 f_high3], Fs3);
In this instance, a loop is likely not the most efficient option.
NOTE — rdmat.m is a Physionet file.
.

カテゴリ

Help Center および File ExchangeDescriptive Statistics についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by