How would one find the minimum value in each row, and also the index of the minimum value?
octave:1> a = [1 2 3; 9 8 7; 5 4 6]
a =
1 2 3
9 8 7
5 4 6
This is hard to find in the documentation. https://www.gnu.org/software/octave/doc/v4.0.3/Utility-Functions.html
octave:2> [minval, idx] = min(a, [], 2)
minval =
1
7
4
idx =
1
3
2