IQR Calculator: Interquartile Range, Box Plot & Outliers
Eleven days of phone screen time run from 95 to 210 minutes, and then one day shows 415. Is that day an outlier, or just a long Sunday? The interquartile range (IQR) answers it. It measures the spread of the middle half of your data, and from it come the fences that decide which values sit unusually far out.
Type or paste your values and the calculator returns the IQR, the five-number summary, both fences, every outlier (with the extreme ones marked) and a box plot showing each value. Because textbooks, calculators and spreadsheets don’t agree on how to find quartiles, it also lists the result under four standard methods so you can match your class or software. Two more tabs draw a box plot from a five-number summary alone and compare several groups on one scale. It opens on the screen-time data.
Separate values with commas, spaces or new lines. Order doesn’t matter; the calculator sorts them.
Draws the box plot, finds the IQR and fences, and tells you whether the data must contain an outlier.
Up to 12 groups, at least 3 values each. All boxes are drawn on one scale.
Eleven Days of Screen Time, Worked to the Fences
Sorted, the eleven daily totals in minutes are:
95, 101, 120, 133, 142, 156, 168, 175, 188, 210, 415
- Median. With 11 values the median is the 6th: 156.
- Lower half. Leave the median out and take the five values below it: 95, 101, 120, 133, 142. Their median is Q1 = 120.
- Upper half. The five values above the median: 168, 175, 188, 210, 415. Their median is Q3 = 188.
- IQR = Q3 − Q1 = 188 − 120 = 68 minutes. The middle half of the days spans 68 minutes.
- Fences. 1.5 × 68 = 102, so the lower fence is 120 − 102 = 18 and the upper fence is 188 + 102 = 290.
- Outliers. Only 415 is outside. It is even beyond the outer fence, Q3 + 3 × IQR = 392, which makes it an extreme outlier.
The five-number summary is 95, 120, 156, 188, 415. On the box plot, the right whisker stops at 210, the last value inside the fence, and 415 appears as a separate filled dot. If the whisker ran all the way to 415, it would hide the very thing the plot exists to show.
Four Methods, Four Answers: Match Your Class or Software
The steps above are the method taught in many textbooks and used by the TI-83 and TI-84: split at the median and leave the median out of both halves when the count is odd. It is not the only method, and for these eleven values the alternatives give a noticeably different IQR:
| Method | Used by | Q1 | Q3 | IQR |
|---|---|---|---|---|
| Median of halves, middle value left out | TI-83/84, many textbooks | 120 | 188 | 68 |
| Median of halves, middle value included | Tukey’s hinges | 126.5 | 181.5 | 55 |
| Interpolated, position (n − 1)p + 1 | Excel QUARTILE.INC, Sheets QUARTILE | 126.5 | 181.5 | 55 |
| Interpolated, position (n + 1)p | Excel QUARTILE.EXC, Minitab | 120 | 188 | 68 |
The gap is 13 minutes, nearly a quarter of the IQR, from the same eleven numbers. None of these is wrong; they are different definitions. When your answer doesn’t match the key, the method is the first thing to check, and the calculator’s menu switches between all four.
An even count changes the picture. Add a twelfth day of 230 minutes and the two halves split cleanly, six values each, so both median-of-halves methods agree: Q1 = 126.5, Q3 = 199, IQR = 72.5. The interpolated methods still differ, giving 63.75 (QUARTILE.INC) and 81.25 (QUARTILE.EXC).
Two practical notes. In Excel, =QUARTILE.INC(A1:A11, 1) gives 126.5 and =QUARTILE.EXC(A1:A11, 1) gives 120. Google Sheets’ plain QUARTILE behaves like QUARTILE.INC. On a TI-84, enter the data in L1 and run 1-Var Stats from STAT → CALC; Q1 and Q3 appear further down the output list. The differences come from where each method places a quartile between neighbouring values, so they shrink as the data set grows. The percentile calculator goes deeper into the interpolation formulas.
Why the Fences Sit at 1.5 × IQR
The 1.5 multiplier comes from John Tukey’s Exploratory Data Analysis (1977), the book that made the box plot widely known. It is a convention, not a law, and it has a clear meaning for bell-shaped data:
- In a normal distribution, Q1 and Q3 sit 0.6745 standard deviations from the mean, so the IQR equals 1.349 SD.
- The 1.5 × IQR fences then land at ±2.698 SD. Only 0.70% of normal data falls outside them.
- The 3 × IQR outer fences land at ±4.72 SD, where about 2 values in a million fall.
That 0.70% matters for big data sets. With 1,000 values from a perfectly normal process, about 7 will be flagged as outliers even though nothing is wrong with them. Skewed data get flagged more often: for exponentially distributed values, such as times between random events, 4.8% land above the upper fence. A flag says “look at this value”, not “delete this value”. The NIST Engineering Statistics Handbook uses the same two levels, calling points beyond the inner fences mild outliers and points beyond the outer fences extreme outliers.
The Outlier fences menu offers 1.5 × IQR (the standard), 3 × IQR (extreme only), and 2 × or 1 × IQR for checking how sensitive a conclusion is to the cut-off.
What One Outlier Does to the Range, SD and IQR
Remove the 415-minute day and compare:
| Measure | All 11 days | Without 415 | Change |
|---|---|---|---|
| Range | 320 | 115 | −64% |
| Standard deviation | 87.81 | 37.56 | −57% |
| Mean | 173.0 | 148.8 | −14% |
| IQR | 68 | 55 | −19% |
| Median | 156 | 149 | −4% |
The IQR moves partly because the data set shrinks from 11 values to 10 and the quartile positions shift. The extreme value itself has no pull on it. Change 415 to a typo of 4,150 and the IQR stays at 68 while the standard deviation jumps to 1,206.9 and the mean to 512.5. That resistance is why the IQR and median are reported for incomes, house prices, response times and other data with long tails. Report the standard deviation when the data are roughly symmetric without outliers, or alongside the IQR.
A quick check combines both: for normal data, IQR ÷ 1.349 should be close to the SD. Here 68 ÷ 1.349 = 50.4 while the SD is 87.8, a sign that one tail stretches far beyond the middle. The calculator lists this comparison with its results.
A Box Plot From Five Numbers Only
Reports and papers sometimes print only the five-number summary. Suppose a salary survey (in $1,000s) gives minimum 31, Q1 42, median 48, Q3 57 and maximum 96. The Five-number summary tab works from just these:
- IQR = 57 − 42 = 15, fences at 42 − 22.5 = 19.5 and 57 + 22.5 = 79.5.
- The maximum, 96, is above the upper fence, so the data must contain at least one outlier, even though the individual salaries are unknown.
- The four quarter widths are 11, 6, 9 and 39. Each quarter holds about a quarter of the people, so the top quarter of salaries is spread over a range more than four times as wide as either middle quarter.
The tab also gives IQR ÷ 1.349 = 11.12 as the standard deviation the salaries would have if they were normal. With a maximum that far past the fence, the real SD is probably larger, so don’t take that figure as the actual SD of the survey.
What the summary can’t tell you is where the upper whisker should stop, because the last salary inside the fence isn’t known. The calculator draws the whiskers to the minimum and maximum and says so.
Reading Skew From the Box: Bowley’s Coefficient
The position of the median inside the box shows the shape of the middle half. Bowley’s coefficient puts a number on it:
Bowley skewness = (Q3 + Q1 − 2 × median) ÷ (Q3 − Q1)
It runs from −1 to +1. For the salaries, (57 + 42 − 96) ÷ 15 = 0.2: the median sits closer to Q1, the upper half of the box is longer, and the data lean right. A median closer to Q3 gives a negative value and a left lean.
The screen-time data show why the box alone isn’t the whole story. Their Bowley coefficient is (188 + 120 − 312) ÷ 68 = −0.06, a nearly symmetric middle half. Yet the mean (173) sits well above the median (156), pulled by the 415-minute day. The middle is balanced; one tail is not. Read the box and the whiskers together.
When the IQR Comes Out as Zero
Twelve customers rate a service from 1 to 5: 2, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5. Every method gives Q1 = Q3 = 4, so the IQR is 0. The fences collapse onto 4, and the 2, the 3 and both 5s are all flagged as outliers, which says nothing useful. A zero or tiny IQR happens whenever half the values or more are identical, as with ratings, counts of children or shoe sizes. For data like these, report how many answers fall in each category, or the share above and below the typical answer, instead of an IQR. The calculator warns when Q1 equals Q3.
Comparing Groups on One Scale
Box plots work best side by side. Two classes of 15 students sat the same test:
| Class | Min | Q1 | Median | Q3 | Max | IQR |
|---|---|---|---|---|---|---|
| A | 58 | 70 | 77 | 84 | 94 | 14 |
| B | 52 | 71 | 83 | 89 | 99 | 18 |
Class B’s median is 6 points higher and its middle half is a little more spread out. Neither class has an outlier. The boxes overlap heavily, and each median lies inside the other class’s box, so the plot alone does not show a clear difference. When one box sits entirely above the other, or a median falls outside the other box, the shift is larger. The Compare groups tab draws up to 12 groups on one axis and says which of these cases applies. To decide whether a gap like 6 points is more than chance, use a test; the t-test calculator handles two groups of scores.
Reading a Box Plot’s Shape at a Glance
| What you see | What it means |
|---|---|
| Median near the middle of the box, whiskers about equal | Roughly symmetric data |
| Median near Q1, longer right whisker | Right skew: a tail of large values (incomes, waiting times) |
| Median near Q3, longer left whisker | Left skew: a tail of small values (scores on an easy test) |
| Short box, long whiskers | Values cluster in the middle with a wide spread at the edges |
| Long box, short whiskers | Values spread fairly evenly across the middle |
| Dots beyond the whiskers | Values beyond the fences: check each one for errors before drawing conclusions |
| Box with zero width | At least half the values are identical, so the IQR can’t describe the spread |
For the mean, median and mode of the same list, the mean, median and mode calculator gives all three alongside a dot plot.
