Outlier Calculator

This outlier calculator finds Q1, Q3 and the interquartile range and flags values outside the fences. Example: in 12, 15, 11, 18, 14, 16, 13, 17, 40 the fences are 5 and 25, so 40 is an outlier.

Source: Wikipedia – Ausreißer. Updated: .

Separate with spaces or semicolons.
My ToolboxYour inputs are saved in this browser only.

Result

Result
1 outlier(s) found: 40
All values
QuantityValue
Number of values9
First quartile Q112.5
Third quartile Q317.5
Interquartile range IQR5
Lower fence5
Upper fence25
Low outliersnone
High outliers40
Calculation steps
  • Interquartile range: IQR = Q3 − Q1 = 17.5 − 12.5 = 5.
  • Lower fence = Q1 − k · IQR = 12.5 − 1.5 · 5 = 5.
  • Upper fence = Q3 + k · IQR = 17.5 + 1.5 · 5 = 25.
  • Outside [5; 25]: 40.
By Tukey’s rule, values beyond 1.5 × IQR count as outliers. That is a hint, not proof: check whether it is a measurement error or a genuine value.

How it is calculated

Under the IQR rule a value is an outlier if it lies more than 1.5 times the interquartile range below the first or above the third quartile. The rule comes from John Tukey and underlies the whiskers of a box plot.

Steps

First Q1 and Q3 are found, then the interquartile range IQR = Q3 − Q1. The lower fence is Q1 − k · IQR and the upper fence Q3 + k · IQR, with k = 1.5 for outliers and k = 3 for extreme outliers. Every value outside the fences is reported. Because several quartile methods exist, you can choose one; results can differ for small samples.

Example

For 11, 12, 13, 14, 15, 16, 17, 18, 40 (n = 9) the median is 15. The lower half 11–14 gives Q1 = 12.5 and the upper half 16–40 gives Q3 = 17.5, so IQR = 5. The fences are 12.5 − 7.5 = 5 and 17.5 + 7.5 = 25. Only 40 lies above, so it is an outlier; with k = 3 the upper fence is 32.5 and 40 still stands out.

Frequently asked questions

How do you detect outliers?

With the IQR rule: compute Q1, Q3 and the IQR. Values below Q1 − 1.5 × IQR or above Q3 + 1.5 × IQR are outliers.

What does the factor 3 mean?

It sets the fences wider. Values beyond 3 × IQR are called extreme outliers and are especially unusual.

Should I always remove outliers?

No. They can be genuine, rare observations. First check for measurement or entry errors, and document it if you remove a value.

Sources and legal basis

As of: · Editorial policy

Related tools