extract array from a matrix
18 次查看(过去 30 天)
显示 更早的评论
I need to extract the arrays from a tab that contain an assigned value for instance on the Matrix A take all the rows with contain the value 10 on the first column How Can I Do???
0 个评论
采纳的回答
Christian Heigele
2018-8-29
Logical indexing:
A(A(:,1)==10,:)
That states which rows you want to select: A(:,1)==10 , with A(cond, :) you access all those who are selected.
更多回答(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!