how to normalize data between specific range
53 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Muhammad Haziq
am 25 Feb. 2020
Kommentiert: Muhammad Haziq
am 26 Feb. 2020
Hi
I have triangle signal starting from different negative values go to positive values and comeback to negative values. I want them to normalize between 0 and 1 so that there starting values will be same Itried to use this formula.
" normalized_data = data-min(data)/max(data)-min(data)"
by using above values I can align maximum values and ending points but I want to allign its starting point and its maximum point. Can any one help me what should I do.
Regrads,
Haziq
0 Kommentare
Akzeptierte Antwort
Akira Agata
am 25 Feb. 2020
To normalize data to [0 1], you need to add ( ) correctly, like:
normalized_data = (data-min(data))/(max(data)-min(data));
Another (and more easy) way is to use rescale function.
normalized_data = rescale(data);
0 Kommentare
Weitere Antworten (1)
Siehe auch
Kategorien
Mehr zu Bartlett finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!