medoultierfilt

code to remove outliers from a mulitvariate dataset using the median

You are now following this Submission

MEDOUTLIERFILT - remove outliers from a multivariate data set using the
median of each column

[stats_data, filtered_data] = medoutlierfilt(x,outlier_cut,plot_state)
removes possible outliers froma data set, X, by specifiying a cut off.
OUTLIER_CUT is a cut off is a multiple of the inter quartile range above
Q3 and below Q1, default value is the same as BOXPLOT function.

Plot_state = 1 for on, 0 for off, DEFAULT = ON

EXAMPLE:
load count.dat;
[stats, filtered_data] = medoutlierfilt(count,1,1)

Inspired by quartile.m by Chris D. Larson
See also: BOXPLOT, QUARTILE
Colin Clarke 2006
Cranfield Univeristy

Statistics toolbox required for boxplot, if not specifiy boxplot off

As always comments and suggestions welcome!

Cite As

Colin Clarke (2026). medoultierfilt (https://www.mathworks.com/matlabcentral/fileexchange/12958-medoultierfilt), MATLAB Central File Exchange. Retrieved .

Acknowledgements

Inspired by: Quartile & Percentile Calculation

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.0.0.0