how can i remove outliers in my data

2 views (last 30 days)
Preeti
Preeti on 28 May 2018
Commented: Image Analyst on 12 Dec 2019
Hi everyone, Hope everyone doing Good I have some problem. when I run my codes to find the probability I got some errors due to outliers Values. Could anyone help me, how i can remove outlier values? I have a dataset in excel. Thank you :)
  3 Comments
Drewsky3
Drewsky3 on 12 Dec 2019
How would you go about coding this? I am very bad at statistics. . .
Image Analyst
Image Analyst on 12 Dec 2019
Like I said in my Answer below (scroll down past this "Comments" section down to the official "Answers" section at the bottom of the page):
TF = isoutlier(A);
% Now remove outliers from A
A(TF) = []; % or equivalently, A = A(~TF);

Sign in to comment.

Answers (1)

Image Analyst
Image Analyst on 28 May 2018
Did you check the help?
"TF = isoutlier(A) returns a logical array whose elements are true when an outlier is detected in the corresponding element of A. By default, an outlier is a value that is more than three scaled median absolute deviations (MAD) away from the median. If A is a matrix or table, then isoutlier operates on each column separately. If A is a multidimensional array, then isoutlier operates along the first dimension whose size does not equal 1."

Community Treasure Hunt

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

Start Hunting!