Calculate area from a signal
10 vues (au cours des 30 derniers jours)
Hi, would like to calculate area from this emg signal
There are three different channels. I've done RMS and snap the exact tiem I need to analyse but don't know how to calculate total area
My code is:
RMS = Rms_emg (x,100)*1000;
Areatotal(b,c)=sum(S(:,b)); I've tried with this, but don't know if it's correct
Please help, thanks!
AndresVar le 10 Fév 2022
Modifié(e) : AndresVar le 10 Fév 2022
You can use trapezoidal rule: see trapz: Trapezoidal numerical integration - MATLAB trapz (mathworks.com)
area = trapz(x,y) % i think for you trapz(S(:,b)) or just trapz(S(:,b)) if dx = 1
sum also works so you can compare your result. You must multiply the sum by dx, but it looks like dx=1 in your case.