フィルターのクリア

Area for Values in Column

1 回表示 (過去 30 日間)
Lucas MacClellan
Lucas MacClellan 2017 年 11 月 27 日
コメント済み: Lucas MacClellan 2017 年 11 月 27 日
Hello everybody,
I have a matrix A and at the 10th column is the direction of my wind (0-360). Now I want to make an area just form 135-315 and erase the lines which are out of the area.
Here is what I made but something must be wrong...
DI = 135<A(:,10) & A(:,10)<315
A(DI,:) = [];
Thanks
Lucas

採用された回答

KL
KL 2017 年 11 月 27 日
編集済み: KL 2017 年 11 月 27 日
if you want to delete the rows that are not within your range, it should be,
DI = A(:,10)>135 & A(:,10)<315;
A(~DI,:) = [];
  1 件のコメント
Lucas MacClellan
Lucas MacClellan 2017 年 11 月 27 日
Thanks!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMATLAB についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by