I try to normalize the data for each row of Matrix A into deciles.
Matrix A looks like:
[.01 .02 .03 .04 .05;
1 2 3 4 5;
1000 2000 3000 4000 5000];
how to normalize the first row into deciles, then the second row…till the last row? without using ‘for/while’?
The output would be like:
[2 3 6 8 10;
2 3 6 8 10;
2 3 6 8 10];
Look for a script. Thanks!
This should produce something similar to what you are asking for (using
tiedrankfrom the Statistics toolbox):be careful with the rounding and breaks though, you would likely need to adjust the last line in general.
Also: see https://stackoverflow.com/questions/9296568/matlab-normalize-data-into-deciles