Assuming you have already loaded M-wave and H-reflex signals into the workspace as matrices. Here's the code to extract peak-to-peak amplitude with filtering:
main.m677 chars20 lines
This code applies a 4th-order Butterworth bandpass filter between fL and fH frequencies to each M-wave and H-reflex signal. Then, it computes the peak-to-peak amplitude (PPA) for each stimulation step. The output Mwave_ppa
and Href_ppa
are 1D row vectors of length equal to the number of stimulation steps in the input signals.
gistlibby LogSnag