finding the index of a row with a maximum value

6 次查看(过去 30 天)
i am writing a program, and i need to find the row index of a maximum value. the column index is 1, and its a 15x15 matrix.
for i=Z(:,1); m=max(i);
now how do i find the row index of the maximum value?

采纳的回答

Sean de Wolski
Sean de Wolski 2011-12-2
[junk, index] = max(Z(:,1));

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Matrix Indexing 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by