I have a 4 column array, I would like to obtain a vector containing for each row the label of the column which contained the maximum value for this row.
I can do this in loops but I would like to use matrix functions for speed.
How can I do this without programming my own lib functions ?
There is a function that does just this. If
xis your matrix, trymax.col(x).