Powerline interference in ECG
10 ビュー (過去 30 日間)
古いコメントを表示
Could anyone help me with a code for removing 50 Hz in ECG with a notch filter?I'm using this code for now, but the attenuation doesn't seem enough to notice any difference in the signal. Perhaps another kind of filter would do better?
ECG=signal; Fs=300; Fo=50; Fon=Fo/Fs;
f1=45; f2=55; Bz=fir1(2000,[f1/Fs f2/Fs ],'stop'); y2=filter(Bz,1,b);
figure; plot(ECG); figure; plot(y2);
0 件のコメント
回答 (3 件)
Satheeshkumar
2024 年 11 月 16 日
Rejection of 60 Hz power-line interference from ECG signals. Write a Matlab program to implement the notch filter. Apply the filter to the signal in the data file ecg 60hz 200.dat available at DSP, dat files. Plot the ECG signal before and after filtering. Study the nature of the artifacts in the noisy signal and in the output of the filter
0 件のコメント
Star Strider
2024 年 11 月 16 日
Try this —
Fs = 256; % Signal Sampling Frequency
Fn = Fs/2; % Nyquist Frequeency
Ws = [59 61]/Fn; % Passband Frequencies
Wp = Ws+[-1 1]/Fn; % Stopband Freqnencies
Rp = 1; % Passband Ripple (dB)
Rs = 60; % Stopband Ripple (Attenuation) (dB)
[n, Wp] = ellipord(Wp, Ws, Rp, Rs); % Calculate Filter Order
[z,p,k] = ellip(n, Rp, Rs, Wp, 'stop'); % Design Filter
[sos,g] = zp2sos(z, p, k); % Implement Filter As Second-Order-Seection
figure
freqz(sos, 2^20, Fs) % Filter Bode Plot
figure
freqz(sos, 2^20, Fs) % Filter Bode Plot (Deetail)
set(subplot(2,1,1), 'Xlim',[55 65], 'XTick',55:65)
set(subplot(2,1,2), 'Xlim',[55 65], 'XTick',55:65)
Make appropriate changes to work with your signal.
.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Single-Rate Filters についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!