buttLoop error message code lifted from Matlab example 60 Hz hum
--
Using code from Remove the 60 Hz Hum from a Signal.
srate = input ('Enter SAMPLE RATE for this subject(check log book!): ');
ChannelFirst = data.ECG;
Fs=srate;
t =( 0:length(data.ECG)-1)/fs;plot(t,data.ECG);
ylabel 'Voltage (V)', xlabel 'Time (s)'
title 'Open-Loop Voltage with 60 Hz Noise'd = designfilt('bandstopiir','FilterOrder',2, ...
'HalfPowerFrequency1',59,'HalfPowerFrequency2',61, ...
'DesignMethod','butter','SampleRate',Fs);fvtool(d,'Fs',Fs) ; buttLoop = filtfilt(d,openLoop); ERROR THIS LINE <?===========================figure (2);
plot(t,data.ECG,t,buttLoop);
ylabel 'Voltage (V)', xlabel 'Time (s)';
title 'Open-Loop Voltage', legend('Unfiltered','Filtered'); [popen,fopen] = periodogram(data.ECG,[],[],Fs);
[pbutt,fbutt] = periodogram(buttLoop,[],[],Fs); plot(fopen,20*log10(abs(popen)),fbutt,20*log10(abs(pbutt)),'--')
ylabel 'Power/frequency (dB/Hz)', xlabel 'Frequency (Hz)'
title 'Power Spectrum', legend('Unfiltered','Filtered')
ERROR MESSAGE:
Error in HRcodetest (line 120)
buttLoop = filtfilt(d,openLoop);
ANSWER
Matlabsolutions.com provide latest MatLab Homework Help,MatLab Assignment Help for students, engineers and researchers in Multiple Branches like ECE, EEE, CSE, Mechanical, Civil with 100% output.Matlab Code for B.E, B.Tech,M.E,M.Tech, Ph.D. Scholars with 100% privacy guaranteed. Get MATLAB projects with source code for your learning and research.
Looking at the documentation in the link, ‘openLoop’ is loaded in this line:
load openloop60hertz, openLoop = openLoopVoltage;
SEE COMPLETE ANSWER CLICK THE LINK