Normalise data by max envelope value
조회 수: 8 (최근 30일)
이전 댓글 표시
Hi peeps :)
So I have managed to use a function from Lei Wang to normalise my data for ("MVC"), and I need to use the maximum value from this envelope and divide each value in my other two data sets ("FT" and "RFE") by the max MVC value in order to normalise it, but I can't find on here advice/instructions for how I should do this: would anyone be able to point me in the right direction please? :) Here's what I have so far:
t= EMG1MVC(:,1) %finding the envelope of EMG1MVC
y= EMG2MVC(:,2) %finding the envelope of EMG2MVC
[upperEMG1,lowerEMG1] = envelope(t,f1,'analytic') %retrieve envelope data EMG1MVC
[upperEMG2,lowerEMG2] = envelope(y,f1,"analytic") %retrieve envelope data EMG2MVC
댓글 수: 0
답변 (1개)
Zinea
2024년 6월 6일
To normalize the other two datasets (“FT” and “RFE”) using the maximum value from the MVC envelope, you first need to determine the maximum value from the envelopes you have obtained for your MVC data. Once you have this max value, you can divide each value in your “FT” and “RFE” datasets by this maximum value to normalize them.
Here is the code for your reference:
% Assume t, y, and f1 are already defined as per your snippet
[upperEMG1, lowerEMG1] = envelope(t, f1, 'analytic'); % Retrieve envelope data EMG1MVC
[upperEMG2, lowerEMG2] = envelope(y, f1, "analytic"); % Retrieve envelope data EMG2MVC
% Find the maximum value from the MVC envelopes
maxEMG1 = max(upperEMG1);
maxEMG2 = max(upperEMG2);
maxMVC = max(maxEMG1, maxEMG2); % Overall maximum for normalization
% Assuming FT and RFE are your data sets to be normalized
normalizedFT = FT / maxMVC; % Normalize FT
normalizedRFE = RFE / maxMVC; % Normalize RFE
Here, “normalizedFT” and “normalizedRFE” are your normalized datasets.
Hope it helps!
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!