How to find maximum values in large dataset

2 ビュー (過去 30 日間)
abuzer
abuzer 2014 年 5 月 4 日
コメント済み: abuzer 2014 年 5 月 4 日
hello everyone, I have one large data set as a one column matrix and the size (3386718 x 1) and I need to filter some maximum values inside the data. For example most of the values between 0-1 but the some values about 14 and 15.. so I try to find out max values. However I've got this error message
displace=data
c=max(displace)
Subscript indices must either be real positive integers or logicals.
how can I find the max values and remove them from dataset??
Thanks. Mustafa

採用された回答

Image Analyst
Image Analyst 2014 年 5 月 4 日
First of all, 3 million elements not a large dataset by any modern definition. It's like 1/10th the size of a typical point and shoot camera image. Anyway, you can simply threshold to get a map of where the outlier pixels are:
badElements = displace > 1; % Or whatever value you want.
To remove them from your array, do this:
displace(badElements) = [];
  1 件のコメント
abuzer
abuzer 2014 年 5 月 4 日
Thank you very much. it solved my problem.

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

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by