How can I remove elements between certain limits?

Hi
I know this is a basic problem. I have a vector of random numbers. I now need to loop through and and remove any elements which are < 0 or > 1000 but am having problems. Would anyone have any suggestions how to go about this please?
Thanks

 採用された回答

Azzi Abdelmalek
Azzi Abdelmalek 2013 年 12 月 29 日

0 投票

A(A<0 | A>1000)=[]

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeLoops and Conditional Statements についてさらに検索

質問済み:

2013 年 12 月 29 日

コメント済み:

2013 年 12 月 29 日

Community Treasure Hunt

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

Start Hunting!

Translated by