フィルターのクリア

Matrix sorting re-size problem

3 ビュー (過去 30 日間)
satendra kumar
satendra kumar 2012 年 11 月 9 日
Hi everyone, Lets say i have a matrix a=[1 2 3; 1 0 3; 2 3 5; 1 0 5] like that i have 1000 rows. Now i want to remove the rows whose second column element is 0. i.e. if(a(i,2)==0) then remove it. Pls help me out of this. Thanks

採用された回答

Srinivas
Srinivas 2012 年 11 月 9 日
a(a(:,2) ==0,:) = []
  1 件のコメント
satendra kumar
satendra kumar 2012 年 11 月 9 日
Thanks a lot man. You saved my life

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeShifting and Sorting Matrices についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by