ProMathTools
ProMathTools

IQR Calculator – Quartiles, Five-Number Summary & Box Plot

Five-number summary, IQR, Tukey fences, outliers, and an inline SVG box plot — with TI-84/Tukey and Excel quartile methods.

e.g. 1, 2, 3, 4, 5, 6, 7, 8, 9 — commas, spaces, tabs, or semicolons

How it works

Quartile definitions differ across textbooks and software, so the same list can produce different Q1 and Q3 values. Pick a method that matches your class or spreadsheet, then read the five-number summary (min, Q1, median, Q3, max), the IQR, Tukey 1.5×IQR fences, flagged outliers, and an inline SVG box plot. Whiskers stop at the most extreme non-outlier; outliers appear as separate dots.

Required Inputs & Typical Use Cases

Use this tool for AP Stats homework, lab reports that need a box-and-whisker plot, checking spreadsheet QUARTILE.INC / QUARTILE.EXC results, or screening a dataset for Tukey outliers before fitting a model.


The Formula

IQR = Q3 − Q1
Lower fence = Q1 − 1.5×IQR
Upper fence = Q3 + 1.5×IQR
Outlier if x < lower fence or x > upper fence
  • Q1

    First quartile (25th percentile)

  • Q3

    Third quartile (75th percentile)

  • IQR

    Interquartile range


Worked Example

  1. 1…9, exclude median (TI-84/Tukey)

    Lower half 1–4 → Q1 = 2.5; upper half 6–9 → Q3 = 7.5; IQR = 5.

  2. 1…9, Excel QUARTILE.INC

    Q1 = 3, Q3 = 7.

  3. Outlier example

    Data 1…9, 50: value 50 lies above Q3 + 1.5×IQR and is plotted as a red dot.


Tips, Assumptions & Limitations

  • Default method matches TI-84 / Tukey hinges (exclude median).
  • Switch to Excel INC/EXC when matching a spreadsheet.
  • Whiskers stop at the most extreme non-outlier; outliers are separate dots.
  • Methods disagree because they define the lower/upper half differently or interpolate percentiles at different indices.
  • Common mistake: comparing an Excel Q1 with a TI-84 Q1 without matching the method.

IQR = Q3 − Q1, the spread of the middle 50% of the data. It is less sensitive to outliers than the full range.

There is no single universal rule for Q1/Q3. TI-84/Tukey excludes the median from each half when n is odd; some textbooks include it; Excel QUARTILE.INC interpolates at (n−1)p and QUARTILE.EXC at (n+1)p. Choose the method your course or software uses.

Using Tukey fences: values below Q1 − 1.5×IQR or above Q3 + 1.5×IQR are flagged as outliers and shown as dots on the box plot.

Minimum, Q1, median, Q3, and maximum — the skeleton of a box-and-whisker plot.

The box runs from Q1 to Q3 with a median line inside. Whiskers reach the farthest non-outlier values; points beyond the 1.5×IQR fences are plotted as dots.

Match your course or software: TI-84/Tukey (exclude median) is the default here; use Include median for some textbooks; use Excel QUARTILE.INC or QUARTILE.EXC when reproducing a spreadsheet.

Related Calculators

Mean absolute deviationMedian CalculatorStandard Deviation CalculatorMean CalculatorData VisualizationCorrelation CoefficientLinear RegressionSample Size CalculatorT-Test CalculatorModeVarianceZ-Score

Related Guides


How this calculator works

When you're looking at a set of numbers, understanding how spread out they are is just as important as knowing their average. The Interquartile Range (IQR) is a powerful statistical tool that helps you do just that. It gives you a clear picture of the variability within the middle 50% of your data, making it a robust measure that isn't easily swayed by extreme values.

Explanation

The Interquartile Range (IQR) is a key concept in descriptive statistics, providing insight into the spread of the central portion of a data set. Unlike the full range (which is simply the difference between the highest and lowest values), the IQR focuses on the 'middle ground' by excluding the lowest 25% and highest 25% of data points. This makes it particularly useful when your data might contain outliers that could distort other measures of spread. To calculate the IQR, you first need to identify two critical points: the First Quartile (Q1) and the Third Quartile (Q3). Q1 represents the 25th percentile of the data, meaning 25% of the data falls below this value. Q3 represents the 75th percentile, with 75% of the data falling below it. Once you have these, the IQR is simply the difference between them.

Formula

To calculate the Interquartile Range (IQR), follow these steps: 1. **Sort the Data:** Arrange all the numbers in your data set from smallest to largest. 2. **Find the First Quartile (Q1):** This is the value below which 25% of the data falls. It's essentially the median of the lower half of your sorted data. 3. **Find the Third Quartile (Q3):** This is the value below which 75% of the data falls. It's the median of the upper half of your sorted data. 4. **Calculate IQR:** Subtract Q1 from Q3. **IQR = Q3 - Q1** For calculating Q1 and Q3, especially with an even number of data points or when the quartile position isn't a whole number, interpolation methods are often used to ensure accuracy.

Worked example

Let's walk through an example to see how the IQR is calculated. Consider the following data set representing test scores: 10, 15, 20, 25, 30, 35, 40, 45. 1. **Sorted Data:** 10, 15, 20, 25, 30, 35, 40, 45 (n=8) 2. **Calculate Q1:** The position for Q1 (25th percentile) is at index 0.25 * (8 - 1) = 1.75. We interpolate between the 1st (15) and 2nd (20) values (0-indexed). Q1 = 15 + 0.75 * (20 - 15) = 15 + 0.75 * 5 = 15 + 3.75 = **18.75**. 3. **Calculate Q3:** The position for Q3 (75th percentile) is at index 0.75 * (8 - 1) = 5.25. We interpolate between the 5th (35) and 6th (40) values. Q3 = 35 + 0.25 * (40 - 35) = 35 + 0.25 * 5 = 35 + 1.25 = **36.25**. 4. **Calculate IQR:** IQR = Q3 - Q1 = 36.25 - 18.75 = **17.5**. This means the middle 50% of the test scores are spread across a range of 17.5 points.

How to use this tool

Using our Interquartile Range Calculator is straightforward. Simply enter your data points into the 'Data Set' input field. You can separate your numbers using commas, spaces, or even new lines. For example, you could type '10, 15, 20, 25, 30' or '10 15 20 25 30'. Once you've entered your data, the calculator will instantly sort your numbers and display the calculated First Quartile (Q1), Third Quartile (Q3), and the final Interquartile Range (IQR). This provides a quick and accurate way to understand the central spread of your data without manual calculations.

Frequently asked questions

What is the Interquartile Range (IQR)?
The Interquartile Range (IQR) is a measure of statistical dispersion, or how spread out your data is. It represents the range of the middle 50% of your data, calculated as the difference between the third quartile (Q3) and the first quartile (Q1).
How do you calculate Q1 and Q3?
To calculate Q1 (first quartile), you first sort your data set in ascending order. Q1 is the median of the lower half of the data. Similarly, Q3 (third quartile) is the median of the upper half of the data. Our calculator uses a standard interpolation method to find these values accurately.
Why use IQR instead of the full range?
The IQR is often preferred over the full range (maximum value - minimum value) because it is less affected by outliers. Since it focuses on the middle 50% of the data, extreme values at either end do not skew the measure of spread, giving a more robust understanding of the central variability.
Can I use this for small data sets?
While you can technically calculate IQR for small data sets, it becomes more meaningful with at least 4 or more data points. For very small sets, the quartiles might not represent a clear 'middle 50%' effectively.

Read the full guide →

About UsBlogChrome ExtensionFAQsTerms and ConditionsPrivacy PolicySitemap
EmailLinkedInFacebook

© 2025-2026 PromathTools. All rights reserved.

Built by KruskalCode – SaaS & Automation Experts · EverydayDevTools