Deleting rows of a matrix based on values from another matrix
古いコメントを表示
I have a m x 3 matrix A, and a nx1 matrix B. I need to remove those rows of A if either column 1 or 2 of the matrix equals any value in B.
採用された回答
その他の回答 (1 件)
Kritarth Sinha
2022 年 7 月 8 日
編集済み: Kritarth Sinha
2022 年 7 月 8 日
0 投票
Hello Hari,
You can simply use nested loops and for each value in column 1 or 2,you can check that is present in matrix B and do it accordingly.
Hope this will help.
カテゴリ
ヘルプ センター および File Exchange で Matrix Indexing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!