Only have a frequency table with classes and counts? Get Q1, the median, Q3 and any percentile by interpolation, with the cumulative table, every step written out, and gaps or open classes handled.
Grouped Data Quartile Calculator - Q1, Median, Q3, IQR
Only have a frequency table with classes and counts? Get Q1, the median, Q3 and any percentile by interpolation, with the cumulative table, every step written out, and gaps or open classes handled.
Parameters
Enter data for calculations
💡 Fill in all required fields to unlock the calculate button
Quartiles of grouped data, straight from a frequency table
When the data arrive as classes and counts, such as 160-165 cm: 18 people, the raw values are gone and a quartile has to be estimated inside its class. This grouped data quartile calculator finds Q1, the median and Q3 by linear interpolation, prints the cumulative frequency table with the quartile classes marked, and writes out each step. It also handles what textbook tables and census tables actually contain: gaps such as 10-19 and 20-29, an open first or last class such as "under 20" or "65+", and classes of different widths. Any percentile or decile works the same way.
Four steps from a class table to Q1, the median and Q3
- Paste the table, one class per line: the interval, then its frequency, as in
160-165; 18. A space, tab, colon or "160 to 165" also work. Open classes go first asunder 150; 3or last as180+; 2. - Pick the statistic: all three quartiles, one of them, or a percentile from 1 to 99 (10, 20 and so on give the deciles).
- Pick the position rule your course or source uses, k × N / 4 or k × (N + 1) / 4, and whether gaps between classes are closed with class boundaries.
- Read the quartiles, the interquartile range, the quartile deviation and Bowley skewness, then check the marked classes in the cumulative table.
The grouped quartile formula on one card
The quartile class is the first one whose cumulative frequency reaches the position k × N / 4. The formula assumes the observations inside that class are spread evenly, which is why a grouped quartile is an estimate and quartiles from the raw values usually differ slightly. For a percentile, replace k / 4 with the percentage divided by 100.
Eighty heights in six classes
| Height (cm) | Frequency | Cumulative | Holds |
|---|---|---|---|
| 150-155 | 4 | 4 | |
| 155-160 | 12 | 16 | |
| 160-165 | 18 | 34 | Q1, position 20 |
| 165-170 | 24 | 58 | Median, position 40 |
| 170-175 | 16 | 74 | Q3, position 60; P90 at 72 |
| 175-180 | 6 | 80 |
Median = 165 + (40 - 34) / 24 × 5 = 166.25
Q3 = 170 + (60 - 58) / 16 × 5 = 170.63
P90 = 170 + (72 - 58) / 16 × 5 = 174.38
The interquartile range is 170.63 - 161.11 = 9.51 cm, the quartile deviation half of that, 4.76. Bowley skewness, (Q3 + Q1 - 2 × median) / IQR, is -0.080: the middle half of the heights is close to symmetric.
Gaps, open ends and uneven widths
N / 4 or (N + 1) / 4: how far apart the answers land
| Table and rule | Q1 | Median | Q3 | IQR |
|---|---|---|---|---|
| 80 heights, k × N / 4 | 161.11 | 166.25 | 170.63 | 9.51 |
| 80 heights, k × (N + 1) / 4 | 161.18 | 166.35 | 170.86 | 9.68 |
| 50 ages, k × N / 4 | 25.75 | 33.50 | 40.06 | 14.31 |
| 50 ages, k × (N + 1) / 4 | 25.96 | 33.75 | 40.89 | 14.93 |
Most statistics textbooks use N / 4 for grouped data; some exam boards and older texts use N + 1. The gap shrinks as N grows, so it only matters when your answer has to match a marking scheme.
Grouped quartile questions
Related tools
Confidence Interval Calculator
An interval for a mean or a proportion once you have the raw values or a summary - See calculator
Standard Error Calculator
How precisely a mean or a rate is known, from data, an SD and n, or a report - See calculator
Interquartile Range Calculator
Quartiles, IQR and outlier fences from a raw list, under five software conventions - See calculator
Percentile Calculator
Any percentile or percentile rank from a list of values - See calculator
Mode Calculator
The most frequent value, and the modal class with its grouped estimate - See calculator
Median Calculator
The middle value of a plain list of numbers - See calculator
Skewness Calculator
Moment-based skewness with a significance test, next to Bowley's quartile measure used here - See calculator