How to Find Quartiles and the Interquartile Range

Splits the data at the median and takes the median of each half to get the first and third quartiles. The interquartile range Q₃ − Q₁ measures the spread of the middle 50% of the data.

The quartiles are the three values that cut sorted data into four equal parts: the first quartile Q1Q_1, the second Q2Q_2 (the median) and the third Q3Q_3.

To find them, split the data at the median into a lower and an upper half, then take the median of each half. When the count is odd, the median itself is excluded from both halves.

IQR=Q3Q1\text{IQR} = Q_3 - Q_1

The interquartile range is the width of the middle 50% of the data.

Example

Take the eight values 12, 15, 18, 20, 25, 28, 31, 40.

IQR=29.516.5=13\text{IQR} = 29.5 - 16.5 = 13

Where it is used

The quartiles are exactly what a box plot draws: the bottom of the box is Q1Q_1, the line inside it is the median, and the top is Q3Q_3.

Unlike the standard deviation, they are barely affected by outliers. A common rule flags any value below Q11.5×IQRQ_1 - 1.5 \times \text{IQR} or above Q3+1.5×IQRQ_3 + 1.5 \times \text{IQR} as an outlier.