フィルターのクリア

How to remove outliers from data set

1 回表示 (過去 30 日間)
Katara So
Katara So 2020 年 12 月 17 日
コメント済み: Star Strider 2020 年 12 月 17 日
I have the data set:
flintLead=[0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 ...
4 4 5 5 5 5 5 5 5 5 6 6 6 6 7 7 7 8 8 9 10 10 11 13 18 20 21 22 29 43 43 104];
And I want to do one calculation using the whole set and one where I remove the points 20 and 104, but I don't know how to remove just those two points. I thought about doing something like:
without_ouliers = flintLead(1:64, 64:70)
but that's clearly not how it is done. Could someone explain how to remove them? All help is appreciated!

採用された回答

Star Strider
Star Strider 2020 年 12 月 17 日
Try this:
flintLead=[0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 ...
4 4 5 5 5 5 5 5 5 5 6 6 6 6 7 7 7 8 8 9 10 10 11 13 18 20 21 22 29 43 43 104];
flintLead = flintLead(~((flintLead == 20) | (flintLead == 104)))
.
  2 件のコメント
Katara So
Katara So 2020 年 12 月 17 日
Yes, that worked perfect! Thank you so much!
Star Strider
Star Strider 2020 年 12 月 17 日
As always, my pleasure!

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

その他の回答 (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