Home » Statistics & Probability Calculators » Quartiles and IQR Calculator

Quartiles and IQR Calculator

Home › Statistics & Probability Calculators › Quartiles and IQR Calculator

Quartiles and IQR Calculator

Enter a list of values to get the first quartile (Q1), the median (Q2), the third quartile (Q3), the interquartile range (IQR = Q3 − Q1) and the 1.5 × IQR fences used to flag outliers. Because textbooks and software disagree on how to locate a quartile, you can pick the convention your course uses: linear interpolation (Excel QUARTILE.INC, NumPy, R type 7), the median-of-halves rule (Tukey’s hinges, used by the TI-84 and most school textbooks) or the exclusive (n + 1) method (Excel QUARTILE.EXC, Minitab).

The IQR describes the spread of the middle 50% of the data and is not affected by extreme values, which makes it the natural partner of the median. A value below Q1 − 1.5 × IQR or above Q3 + 1.5 × IQR is usually treated as an outlier and is drawn as a separate point on a box plot.

The worked steps sort the data, locate each quartile position, interpolate where needed and then compute the fences, so you can see exactly why two methods sometimes give slightly different answers on small data sets.

Separate values with commas, spaces or new lines.

Result and step-by-step solution

Q1 (25th percentile)21
Q2 (median)42
Q3 (75th percentile)45.75
IQR = Q3 − Q124.75
Fences (1.5 × IQR)−16.125 and 82.875
Outliersnone
  1. Sort the data (n = 10)
    7, 9, 16, 36, 39, 45, 45, 46, 48, 51
  2. Median (Q2)
    42
  3. Locate Q1 and Q3
    Position of Q1 = 0.25 × (n − 1) + 1 = 3.25, position of Q3 = 0.75 × (n − 1) + 1 = 7.75; interpolate between neighbouring sorted values. Q1 = 21, Q3 = 45.75.
  4. Interquartile range
    IQR = 45.75 − 21 = 24.75
  5. Outlier fences
    Lower = Q1 − 1.5 × IQR = −16.125; upper = Q3 + 1.5 × IQR = 82.875. No values fall outside the fences.

Frequently asked questions

Why do different calculators give different quartiles?
There are several accepted rules for locating a quartile between two data points. On large data sets they agree closely; on small ones they can differ. Use the method your textbook or software uses and state it in your answer.
How do I find outliers with the IQR?
Compute IQR = Q3 − Q1. Any value below Q1 − 1.5 × IQR or above Q3 + 1.5 × IQR is an outlier under the usual rule. Some courses use 3 × IQR for “extreme” outliers.
Which method does the TI-84 use?
The TI-84 splits the sorted data at the median, leaving the median out when n is odd, and takes the medians of each half. That is the “median of halves (Tukey)” option here.
Is the IQR better than the standard deviation?
It is more robust: outliers barely change it. The standard deviation uses every value and is preferred for roughly bell-shaped data and for inference.

Last reviewed: September 25, 2026. Calculations run in your browser and were validated against SciPy.

Scroll to Top