Skip to content

Quartile

  • Quartiles split a dataset into four equal parts to summarize its distribution.
  • The three quartiles are Q1 (lower quartile), Q2 (median), and Q3 (upper quartile).
  • Use the interquartile range (IQR = Q3 − Q1) to measure the central spread of the data.

Quartiles are statistical measures that divide a dataset into four equal parts, or quarters. There are three quartiles: the lower quartile (first quartile or Q1), the median (second quartile or Q2), and the upper quartile (third quartile or Q3).

To calculate quartiles, first arrange the data in ascending order. Then divide the ordered dataset into parts and find medians as follows (as illustrated in the examples below):

  • Q1 (lower quartile) is the median of the first part of the ordered data.
  • Q2 (median) is the middle value of the ordered dataset.
  • Q3 (upper quartile) is the median of the second part of the ordered data.

Quartiles summarize the distribution of values and can be used to compare datasets. The interquartile range (IQR), defined as the difference between Q3 and Q1, measures the central spread of the data.

Example: Computing quartiles for a 9-value dataset

Section titled “Example: Computing quartiles for a 9-value dataset”

Consider the dataset: 10, 15, 20, 25, 30, 35, 40, 45, 50

  • For the lower quartile, divide the dataset into two parts. The first part contains the first four values (10, 15, 20, 25), and the second part contains the remaining five values (30, 35, 40, 45, 50). The lower quartile is the median of the first part, which is the average of the two middle values (20 and 25). Therefore, Q1 = 22.5.

  • For the median, divide the dataset into two parts. The first part contains the first five values (10, 15, 20, 25, 30), and the second part contains the remaining four values (35, 40, 45, 50). The median is the middle value of the dataset, which is 30. Therefore, Q2 = 30.

  • For the upper quartile, divide the dataset into two parts. The first part contains the first six values (10, 15, 20, 25, 30, 35), and the second part contains the remaining three values (40, 45, 50). The upper quartile is the median of the second part, which is the average of the two middle values (45 and 50). Therefore, Q3 = 47.5.

The interquartile range is: IQR=Q3Q1=47.522.5=25.\text{IQR} = Q_3 - Q_1 = 47.5 - 22.5 = 25. This indicates that most values fall between 22.5 and 47.5 for this dataset.

Dataset A: 10, 20, 30, 40, 50

Dataset B: 15, 25, 35, 45, 55

If we calculate the quartiles for both datasets, Q1, Q2, and Q3 are the same for both datasets. However, the values in dataset B are all larger than the values in dataset A. This tells us that dataset B has a higher average value than dataset A.

  • Summarizing the distribution of values within a dataset.
  • Measuring spread of central values using the interquartile range (IQR).
  • Comparing distributions between datasets.
  • Median (Q2)
  • Interquartile range (IQR)