标签: matlab matlab-figure
我已经编写了代码以查找所有峰值,但是我还需要查找所有信号中的所有最大峰值:
figure(2); [PKS,LOCS] = findpeaks(PPG); plot(t,PPG,'b-',t(LOCS),PPG(LOCS),'ro','LineWidth',2); grid on; xlabel('Tiempo (seg)'); ylabel('PPG'); meanCycle = mean(diff(LOCS))
图: enter image description here