Interquartile Range (IQR)

April 12, 2026

Problem

Calculate IQR for {1, 3, 5, 7, 9, 11, 13, 15, 17}. Show IQR as the middle 50%.

Explanation

What is the IQR?

The interquartile range = Q3Q1Q3 - Q1. It measures the spread of the middle 50% of the data, ignoring the extreme 25% on each end. It's robust to outliers (unlike range or standard deviation).

Step-by-step: {1, 3, 5, 7, 9, 11, 13, 15, 17}

n=9n = 9. Median = 9 (5th value).

Q1 = median of {1, 3, 5, 7} = (3+5)/2=4(3 + 5)/2 = 4

Q3 = median of {11, 13, 15, 17} = (13+15)/2=14(13 + 15)/2 = 14

IQR=Q3Q1=144=10IQR = Q3 - Q1 = 14 - 4 = 10

IQR vs Range vs SD

  • Range (maxmin=171=16\text{max} - \text{min} = 17 - 1 = 16): Uses only extremes. Very sensitive to outliers.
  • IQR (=10= 10): Uses only the middle 50%. Robust to outliers.
  • SD: Uses all data. Moderately sensitive to outliers.

Try it in the visualization

The data is sorted. The middle 50% is highlighted. Q1 and Q3 are marked, and the IQR is shown as the distance between them.

Interactive Visualization

Parameters

Your turn

Got your own math or physics problem?

Turn any problem into an interactive visualization like this one — powered by AI, generated in seconds. Free to try, no credit card required.

Sign Up Free to Try It30 free visualizations every day
Interquartile Range (IQR) | MathSpin