Find maximum value of each row in a double matrix
1 次查看(过去 30 天)
显示 更早的评论
I have a matrix A double with columns and rows. All the data of A are numbers. I would like to find the maximum value of each row in this matrix.
I tried:
for i=length(A)
MAXIMUMO(i)=max(A(i,:))
end
But it keep onle the last row maximum, whereas the rest data are zero.
Could you please help me?
0 个评论
采纳的回答
KALYAN ACHARJYA
2021-2-21
编辑:KALYAN ACHARJYA
2021-2-21
"I would like to find the maximum value of each row in this matrix"
max_row=max(matrix')
%............Note on transpose
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!