I have used this code to sort a 342×2 matrix using the second column as a reference to mantain the correspondence between rows:
[~, s] = sort(minCell(:,2)); minCell(s, :);
The problem is that the result is not correct. Second column has values between 1 and 9000 and it seems it doesn't work well with numbers <100
Anyone of you know how I can fix this problem?
Thanks
Best Answer