Reputation: 23
I have am matrix like this:
S =
2.2100 16.0100
0.0100 9.8100
9.4100 0.0100
Now I want to know the row number of the minimum value in every column. The vector I'm looking for should look like that:
D =
2
3
Thank you for your help.
Upvotes: 2
Views: 3553
Reputation: 977
[val, ind] = min (S)
and you will have the value:
val =
0.010000 0.010000
ind =
2 3
Upvotes: 6