Assuming your input M-wave and H-reflex waveforms are already in MATLAB variables, you can extract the peak-to-peak amplitude for each stimulation step with the following code:
main.m1432 chars36 lines
This code calculates the peak-to-peak amplitude for the M-wave and H-reflex waveform for each stimulation step. It assumes that the raw data is already loaded into MATLAB variables and any necessary pre-processing steps (such as filtering or artifact removal) have been applied. The code uses a loop to process each stimulation step separately and calculates the peak-to-peak amplitude for each waveform using the max()
and min()
functions.
gistlibby LogSnag