Normalise data by max envelope value
8 views (last 30 days)
Show older comments
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 Comments
Answers (1)
Zinea
on 6 Jun 2024
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 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!