What are the quartiles of my data?
Find Q1, the median, Q3, and the interquartile range of your numbers, by the quartile method you choose.
- Interquartile range (IQR)
- 5
With the quartile method set to Median of halves (TI-83), Q1 is 3, the median is 5.5, and Q3 is 8, so the IQR is 5.
- First quartile (Q1)
- 3
- Median (Q2)
- 5.5
- Third quartile (Q3)
- 8
- Minimum
- 1
- Maximum
- 10
- Range
- 9
- Lower fence
- −4.5
- Upper fence
- 15.5
- Outliers
- None
- Count
- 10
Interquartile range (IQR): 5. With the quartile method set to Median of halves (TI-83), Q1 is 3, the median is 5.5, and Q3 is 8, so the IQR is 5.
Box plot of your numbers
How to calculate
Computes the first, second, and third quartiles and the interquartile range of a list of numbers by a named method, with the five-number summary and outliers.
Example with the default inputs (Your numbers [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], Quartile method Median of halves (TI-83)): With the quartile method set to Median of halves (TI-83), Q1 is 3, the median is 5.5, and Q3 is 8, so the IQR is 5.
Method: Sort the numbers; Q2 is the median; Q1 and Q3 follow the chosen method; IQR = Q3 − Q1; outliers lie outside Q1 − 1.5 × IQR and Q3 + 1.5 × IQR.
- The default method (median of halves, median left out) is the old page’s method, so old links show the same quartiles.
- With one number, every quartile is that number.
- Outliers use Tukey’s 1.5 × IQR fences; a value exactly on a fence is not an outlier.
Worked examples
Each example is checked against the calculator on every build.
- Your numbers 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, Quartile method Median of halves (TI-83) gives First quartile (Q1) 3, Median (Q2) 5.5, Third quartile (Q3) 8, Interquartile range (IQR) 5, Lower fence -4.5, Upper fence 15.5, Outliers None.Source: OpenStax, Introductory Statistics 2e, §2.3 Measures of the Location of the Data (quartiles, interquartile range and outliers). https://openstax.org/books/introductory-statistics-2e/pages/2-3-measures-of-the-location-of-the-data
- Your numbers 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, Quartile method Inclusive (Excel QUARTILE.INC) gives First quartile (Q1) 3.25, Median (Q2) 5.5, Third quartile (Q3) 7.75, Interquartile range (IQR) 4.5.Source: NIST/SEMATECH e-Handbook of Statistical Methods, §7.2.6.2 Percentiles (sample quantile definitions). https://www.itl.nist.gov/div898/handbook/prc/section2/prc262.htm
- Your numbers 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, Quartile method Exclusive (Excel QUARTILE.EXC) gives First quartile (Q1) 2.75, Median (Q2) 5.5, Third quartile (Q3) 8.25, Interquartile range (IQR) 5.5.Source: NIST/SEMATECH e-Handbook of Statistical Methods, §7.2.6.2 Percentiles (sample quantile definitions). https://www.itl.nist.gov/div898/handbook/prc/section2/prc262.htm
- Your numbers 1, 2, 3, 4, 5, 6, 7, 8, 9, Quartile method Tukey’s hinges gives First quartile (Q1) 3, Median (Q2) 5, Third quartile (Q3) 7, Interquartile range (IQR) 4.Source: OpenStax, Introductory Statistics 2e, §2.3 Measures of the Location of the Data (quartiles, interquartile range and outliers). https://openstax.org/books/introductory-statistics-2e/pages/2-3-measures-of-the-location-of-the-data
- Your numbers 1, 2, 3, 4, 5, 6, 7, 8, 9, Quartile method Median of halves (TI-83) gives First quartile (Q1) 2.5, Median (Q2) 5, Third quartile (Q3) 7.5, Interquartile range (IQR) 5.Source: OpenStax, Introductory Statistics 2e, §2.3 Measures of the Location of the Data (quartiles, interquartile range and outliers). https://openstax.org/books/introductory-statistics-2e/pages/2-3-measures-of-the-location-of-the-data
- Your numbers 10, 20, 30, 40, 50, 60, 70, 80, 90, 1,000, Quartile method Median of halves (TI-83) gives First quartile (Q1) 30, Median (Q2) 55, Third quartile (Q3) 80, Interquartile range (IQR) 50, Upper fence 155, Outliers 1000.Source: OpenStax, Introductory Statistics 2e, §2.3 Measures of the Location of the Data (quartiles, interquartile range and outliers). https://openstax.org/books/introductory-statistics-2e/pages/2-3-measures-of-the-location-of-the-data
How it works
Sort the n numbers: x₍₁₎ ≤ x₍₂₎ ≤ … ≤ x₍ₙ₎. The median (Q2) is the middle value, or the average of the two middle values when n is even. Q1 and Q3 depend on the method:
- Median of halves (TI-83, Moore and McCabe), the default. Split the sorted list into a lower and an upper half of ⌊n ÷ 2⌋ values each. When n is odd, the median is left out of both halves. Q1 is the median of the lower half and Q3 the median of the upper half.
- Tukey's hinges. The same, but when n is odd the median is kept in both halves (each half has (n + 1) ÷ 2 values).
- Inclusive (Excel QUARTILE.INC, R type 7). The p-quantile is at position h = 1 + (n − 1)p in the sorted list, with p = 0.25, 0.5, 0.75. With j the whole part of h, the quantile is x₍ⱼ₎ + (h − j)(x₍ⱼ₊₁₎ − x₍ⱼ₎).
- Exclusive (Excel QUARTILE.EXC, Minitab, R type 6). The same interpolation at position h = (n + 1)p. A position below 1 or above n is read as the smallest or largest value, so small lists still get quartiles (Excel shows an error there instead).
Then:
- IQR = Q3 − Q1.
- Lower fence = Q1 − 1.5 × IQR and upper fence = Q3 + 1.5 × IQR (Tukey's rule).
- Outliers are the values strictly below the lower fence or strictly above the upper fence, listed from smallest to largest (repeats listed each time) and separated by a comma and a space, or "None". Each is rounded as the page shows numbers (at most 6 decimal places) with no thousands separators.
- The minimum, maximum, range (maximum − minimum), and count complete the five-number summary.
Assumptions
- The default method is the old page's method, so old links give the same quartiles. Every method gives the same median.
- With one number, every quartile is that number and the IQR is 0.
Worked examples by hand
1, 2, 3, 4, 5, 6, 7, 8, 9, 10 (the default list, n = 10). The median is (5 + 6) ÷ 2 = 5.5.
- Median of halves: the halves are 1–5 and 6–10, so Q1 = 3 and Q3 = 8, IQR = 5. The fences are 3 − 7.5 = −4.5 and 8 + 7.5 = 15.5, so there are no outliers.
- Inclusive: h = 1 + 9 × 0.25 = 3.25, so Q1 = 3 + 0.25 × (4 − 3) = 3.25; h = 1 + 9 × 0.75 = 7.75, so Q3 = 7.75. IQR = 4.5.
- Exclusive: h = 11 × 0.25 = 2.75, so Q1 = 2 + 0.75 × 1 = 2.75; h = 11 × 0.75 = 8.25, so Q3 = 8.25. IQR = 5.5.
1, 2, 3, 4, 5, 6, 7, 8, 9 (n = 9, odd). The median is 5.
- Tukey's hinges keep the 5 in both halves: 1–5 and 5–9, so Q1 = 3 and Q3 = 7, IQR = 4.
- Median of halves leaves it out: 1–4 and 6–9, so Q1 = 2.5 and Q3 = 7.5, IQR = 5.
10, 20, 30, 40, 50, 60, 70, 80, 90, 1000 (median of halves). The halves are 10–50 and 60–1000, so Q1 = 30, Q3 = 80, IQR = 50. The upper fence is 80 + 75 = 155, so 1000 is an outlier.
Other questions people ask
What are quartiles and why are they important?
Quartiles divide a dataset into four equal parts, each containing 25% of the data. Q1 (first quartile) is the 25th percentile, Q2 (second quartile) is the median (50th percentile), and Q3 (third quartile) is the 75th percentile. Quartiles help understand data distribution, identify central tendency, and detect outliers.
How are quartiles calculated?
There is more than one standard method, and they can give different Q1 and Q3 for the same data. The default here: 1) Sort data in ascending order, 2) Find the median (Q2), 3) Q1 is the median of the lower half (excluding Q2 if odd number of values), 4) Q3 is the median of the upper half (excluding Q2 if odd number of values). This is the method of the TI-83 and many textbooks. You can also pick Tukey’s hinges, or the inclusive and exclusive methods used by Excel.
Why do different calculators give different quartiles?
Because they use different methods. For 1 to 10, the median-of-halves method gives Q1 = 3 and Q3 = 8, Excel QUARTILE.INC gives 3.25 and 7.75, and Excel QUARTILE.EXC gives 2.75 and 8.25. All three are correct for their method. Pick the method your course or software uses.
What is the interquartile range (IQR) and why is it useful?
The interquartile range (IQR) is Q3 - Q1, representing the middle 50% of the data. It's a robust measure of spread that's not affected by extreme outliers. IQR is used to identify outliers (values beyond Q1 - 1.5×IQR or Q3 + 1.5×IQR) and provides a better measure of variability than range for skewed distributions.
What's the difference between quartiles and percentiles?
Quartiles are specific percentiles: Q1 = 25th percentile, Q2 = 50th percentile (median), Q3 = 75th percentile. While percentiles can be any value (1st, 2nd, 10th, etc.), quartiles specifically divide data into four equal parts. Percentiles provide more granular division of data distribution.
How do I interpret the quartile results?
Q1 shows where 25% of data falls below, Q2 (median) shows the middle value, and Q3 shows where 75% of data falls below. The IQR shows the spread of the middle 50% of data. A large IQR indicates high variability, while a small IQR suggests data is clustered around the median.
What are outliers and how do quartiles help identify them?
Outliers are data points that fall significantly outside the normal range. The 1.5×IQR rule identifies outliers as values below Q1 - 1.5×IQR or above Q3 + 1.5×IQR. Quartiles help establish these boundaries and provide a systematic way to detect unusual values in your dataset.
When should I use quartiles instead of mean and standard deviation?
Use quartiles when your data is skewed, has outliers, or isn't normally distributed. Quartiles are robust statistics that aren't affected by extreme values, unlike mean and standard deviation. They're particularly useful for exploratory data analysis and when you need to understand data distribution patterns.
How do quartiles relate to box plots?
Box plots (box-and-whisker plots) are visual representations of quartiles. The box shows Q1, Q2 (median), and Q3, with the whiskers extending to the minimum and maximum values. Some box plots end the whiskers at the fences and show outliers as individual points. Box plots provide a quick visual summary of data distribution and spread.
What does it mean if Q1 and Q3 are close together?
If Q1 and Q3 are close together, it means the middle 50% of your data is clustered tightly around the median, indicating low variability in the central portion of your dataset. This often suggests a more uniform or consistent distribution in the middle range of your data.
What's the relationship between quartiles and the five-number summary?
The five-number summary consists of minimum, Q1, median (Q2), Q3, and maximum. It provides a complete picture of data distribution and is the foundation for box plots. This summary gives you both the central tendency (median) and spread (range and IQR) of your data in a compact format.
How do quartiles help with data cleaning and validation?
Quartiles help identify potential data quality issues by revealing unusual patterns. Large gaps between quartiles might indicate missing data or measurement errors. Outliers detected through the IQR method can highlight data entry errors, extreme values that need investigation, or genuine but unusual observations.
How do quartiles compare to other measures of central tendency?
Quartiles complement other measures: the median (Q2) is more robust than the mean for skewed data, Q1 and Q3 show where data clusters, and the IQR provides a robust measure of spread compared to standard deviation. Together, they give a comprehensive view of data distribution without being overly sensitive to outliers.
What are some practical applications of quartile analysis?
Quartile analysis is used in quality control (identifying defective products), finance (analyzing investment returns), healthcare (understanding patient data distributions), education (grading systems), and research (comparing groups). It's particularly valuable when you need to understand data distribution patterns and identify unusual values.