I have a 4x800 data. I need to find the max and min value by column and based on the result. I have to change the max value to 1 and the min value to 0. This is my code:
M = A==repmat(max(A),size(A,1),1);
M( cumsum(M)>1 ) = 0;
filename = 'result10.xlsx';
xlswrite(filename,M);
As you can see, I am also writing the results to an Excel file. However, when I open up the file in Excel, it shows true and false values. How do I make the values become 1 and 0?