Trimean Calculator
Statistics
- Sort the 8 values and read off the three quartiles by linear interpolation - the same quartile convention as the interquartile range page: Q1 = 4.00, median = 4.50, Q3 = 5.50.
- Weight the median twice: trimean = (Q1 + 2 x median + Q3) / 4 = (4.00 + 2 x 4.50 + 5.50) / 4.
- The trimean is 4.63, while the ordinary mean of the same data is 5.00.
- Tukey proposed the trimean as a robust centre: the quartiles anchor it, so a single extreme value moves it far less than it moves the mean.
This Trimean Calculator computes the trimean of your data set, Tukey's robust average built from the three quartiles: (Q1 + 2 x median + Q3) / 4. Enter your values and the calculator returns the trimean along with the quartiles it rests on. For the values 2, 4, 4, 4, 5, 5, 7, 9, the quartiles are Q1 = 4.00, median = 4.50 and Q3 = 5.50, giving a trimean of 4.63 against an ordinary mean of 5.00. For five evenly spaced values 10, 20, 30, 40, 50, the trimean is 30.00, matching the mean.
The method follows Tukey's accepted definition, and its weighting explains why it is trusted: counting the median twice anchors the trimean to the middle of the data, while the quartiles keep it informed by the spread. That design makes it robust. A single extreme value moves the trimean far less than it moves the mean, so the result reflects the bulk of the data rather than one outlier. This page shows the formula, step-by-step workings, worked examples and sources, so you can check every number yourself rather than take the output on faith. Whether you are summarizing a small list of readings or comparing the trimean with the ordinary mean, the calculator and the workings together give you a clear, verifiable answer.
Worked examples
Textbook eight values
(8 values · 2 · 4 · 4 · 4 · 5 · 5 · 7 · 9 · 0 · 0)
| trimean of the data set | 4.63 |
| first quartile Q1 | 4.00 |
| median | 4.50 |
| third quartile Q3 | 5.50 |
Five evenly spaced values
(5 values · 10 · 20 · 30 · 40 · 50 · 0 · 0 · 0 · 0 · 0)
| trimean of the data set | 30.00 |
| first quartile Q1 | 20.00 |
| median | 30.00 |
| third quartile Q3 | 40.00 |
Six values with a high tail
(6 values · 3 · 5 · 8 · 12 · 15 · 20 · 0 · 0 · 0 · 0)
| trimean of the data set | 10.00 |
| first quartile Q1 | 5.75 |
| median | 10.00 |
| third quartile Q3 | 14.25 |
What is the trimean?
The trimean is a robust average built from the three quartiles of a data set: (Q1 + 2 x median + Q3) / 4. In words, you take the first quartile, add twice the median, add the third quartile, and divide the total by four. Because the median is counted twice, the trimean is anchored to the middle of the data, while the quartiles keep it informed by the spread on either side. It is often called Tukey's robust average, after the statistician who popularized it.
The formula is easier to trust once you run it on real numbers. Take the eight values 2, 4, 4, 4, 5, 5, 7, 9. For this data set the quartiles are Q1 = 4.00, the median = 4.50 and Q3 = 5.50. Substitute those into the formula: Q1 + 2 x median + Q3 becomes 4.00 + 2 x 4.50 + 5.50. Twice the median is 9.00, so the sum is 4.00 + 9.00 + 5.50 = 18.50. Divide 18.50 by 4 and the trimean is 4.63. The ordinary mean of the same eight values is 5.00, so the trimean sits closer to the center of the data than the mean does.
The weighting is what makes the trimean behave the way it does. Counting the median twice pulls the result toward the middle value, while the two quartiles contribute the remaining half of the weight and keep the measure sensitive to how the data is spread. That combination is why a single extreme value moves the trimean far less than it moves the mean: one outlier can drag the mean a long way, but it has only a limited effect on the quartiles and therefore on the trimean.
The trimean does not always differ from the mean. For five evenly spaced values, 10, 20, 30, 40 and 50, the trimean is 30.00, exactly matching the mean. When the data is symmetric and evenly distributed, the two measures agree; the gap opens up when the data is skewed or contains extreme values, which is the situation the trimean was designed to handle.
How the quartiles are found
To compute a trimean you first need three numbers: the first quartile (Q1), the median, and the third quartile (Q3). The quartiles split the sorted data into four parts, but when the data set is small or the split lands between two values, you have to decide how to pick a number. This page uses the linear-interpolation convention, the same one used on the interquartile range page, so results stay consistent between the two tools.
Here is how that convention works. Sort the values from smallest to largest. The median is the middle value when the count is odd; when the count is even, it is the average of the two middle values. For the quartiles, think of the data as positions along a line from the first value to the last. Q1 sits one-quarter of the way along that line and Q3 sits three-quarters of the way along it. If the position falls between two data values, you take a weighted blend of those two values in proportion to how far the position lies between them. That blend is the linear interpolation.
A worked example makes it concrete. Take the values 2, 4, 4, 4, 5, 5, 7, 9. The quartiles come out as Q1 = 4.00, median = 4.50 and Q3 = 5.50. Feeding those into Tukey's formula, (Q1 + 2 x median + Q3) / 4, gives (4.00 + 9.00 + 5.50) / 4 = 4.63. The ordinary mean of the same values is 5.00, so the two summaries disagree here, and that is expected: the trimean is built to sit closer to the bulk of the data than the mean does.
When the data are evenly spread, the two summaries agree. For the five evenly spaced values 10, 20, 30, 40, 50, the trimean is 30.00, exactly matching the mean. The weighting is what produces this behavior: counting the median twice anchors the trimean to the middle of the data, while Q1 and Q3 keep it informed by the spread on either side. The result is a robust average that responds to the shape of the distribution without being dragged around by a single unusual observation. A single extreme value moves the trimean far less than it moves the mean.
Because the quartile rule is fixed, two people working from the same sorted list will always get the same Q1, median and Q3, and therefore the same trimean. Keep the data sorted before you start, and apply the same interpolation step to both quartiles.
Trimean vs mean and median
The trimean sits between the mean and the median in how it responds to data. The mean uses every value equally, so a single extreme observation pulls it strongly. The median uses only the middle value, so it ignores the spread of the data around that center. The trimean, Tukey's robust average, is built as (Q1 + 2 x median + Q3) / 4 from the three quartiles. Weighting the median twice anchors the trimean to the middle of the data while the quartiles keep it informed by the spread. Comparing all three on the same values shows what that balance means in practice.
Take the values 2, 4, 4, 4, 5, 5, 7, 9. The quartiles are Q1 = 4.00, median = 4.50 and Q3 = 5.50. Putting those into the formula gives a trimean of 4.63, against an ordinary mean of 5.00. The median is 4.50. Here the trimean lands just above the median, because Q3 sits further from the median than Q1 does, and it stays well below the mean, which is lifted by the upper values. The trimean is not simply a copy of either center; it reflects both the middle and the spread.
The difference grows when one value is extreme. In the high-tail example, where a single large observation stretches the upper end of the data, the mean rises to 10.50 while the trimean is 10.00. A single extreme value moves the trimean far less than it moves the mean, because the trimean depends on the quartiles rather than on every individual value. The median is even less affected, but it gives no weight to where the quartiles fall. The trimean keeps some of that information while resisting the pull of the tail.
When the data are symmetric, the three centers agree. For the five evenly spaced values 10, 20, 30, 40, 50, the trimean is 30.00, matching the mean. With no lopsided spread, the quartiles sit evenly around the median, so the weighted average lands on the same center as the ordinary mean. That makes the trimean easy to interpret: where the data are balanced it behaves like the mean, and where they are skewed it stays closer to the middle.
The table below collects the comparisons on the worked data sets.
The choice among the three depends on the question. The mean answers what an equal share per value would be. The median answers what the typical middle value is. The trimean answers a middle question that also accounts for the spread of the quartiles, which is why it is a useful robust summary when a data set contains a high tail.
- For 2, 4, 4, 4, 5, 5, 7, 9: Q1 = 4.00, median = 4.50, Q3 = 5.50, trimean = 4.63, mean = 5.00.
- For 10, 20, 30, 40, 50: trimean = 30.00, matching the mean.
- In the high-tail example: trimean = 10.00, mean = 10.50.
- A single extreme value moves the trimean far less than it moves the mean.
| Data set | Q1 | Median | Q3 | Trimean | Mean |
|---|---|---|---|---|---|
| 2, 4, 4, 4, 5, 5, 7, 9 | 4.00 | 4.50 | 5.50 | 4.63 | 5.00 |
| 10, 20, 30, 40, 50 | 30.00 | 30.00 | |||
| High-tail example | 10.00 | 10.50 |
When to use a trimean
The trimean is worth reaching for when you want a summary that describes the center of a data set without being pushed around by a few unusual values. Because it is built from the three quartiles — (Q1 + 2 x median + Q3) / 4 — it depends only on where the data sit at the middle and at the quarter marks. That makes it a robust average in Tukey's sense: a single extreme value moves the trimean far less than it moves the mean. If your data include one very large or very small observation, the mean can drift toward that value while the trimean stays close to where most of the data actually live.
Skewed data is a natural fit. When a distribution has a long tail on one side, the mean is pulled into the tail, but the trimean keeps its footing. Consider the values 2, 4, 4, 4, 5, 5, 7, 9. Here Q1 = 4.00, the median = 4.50 and Q3 = 5.50, so the trimean is 4.63, while the ordinary mean is 5.00. The gap is small in this example, but it shows the direction: the trimean sits nearer the bulk of the observations. Weighting the median twice anchors the trimean to the middle of the data, while the quartiles keep it informed by the spread. For symmetric data the two summaries agree closely — for five evenly spaced values 10, 20, 30, 40, 50 the trimean is 30.00, matching the mean — so you lose little by using the trimean when you are unsure how much skew or contamination is present.
The trimean also suits box-plot reporting, where the quartiles are already computed. A box plot displays Q1, the median and Q3 directly, so the trimean can be calculated from the same three numbers with no extra pass over the raw data. If you are already describing a distribution with a five-number summary, adding the trimean gives readers a single robust center that is consistent with the box they are looking at. This is especially useful when you report several groups side by side and want one comparable number for each.
Use the trimean when robustness matters more than a familiar label, when the data are skewed or contain outliers, or when quartiles are the summary you already have on hand. Reach for the mean instead when you need the standard arithmetic average, and consider the median alone when you want the simplest possible middle value. The trimean sits between those choices, blending the median's resistance to extremes with information from the spread of the data.
FAQs
How do you calculate the trimean?
Add Q1, twice the median and Q3, then divide by 4. In formula form that is (Q1 + 2 × median + Q3) / 4. The median is counted twice, which gives it more weight than either quartile, so the trimean sits between the median and the midhinge.
What is the trimean of 2, 4, 4, 4, 5, 5, 7, 9?
The trimean is 4.63. For that data the quartiles are 4.00, 4.50 and 5.50, so the calculation is (4.00 + 2 × 4.50 + 5.50) / 4. The plain mean of the same values is 5.00, so here the trimean falls below the mean.
Who proposed the trimean?
John Tukey proposed the trimean, as part of his exploratory data analysis toolkit. Tukey was a statistician who favored simple summary measures that are easy to compute and read. The trimean fits that approach: it combines three familiar quantities, the first quartile, the median and the third quartile, into one number.
Is the trimean the same as the midhinge?
No. The midhinge is (Q1 + Q3) / 2, which uses only the two quartiles. The trimean also counts the median, twice, so the two measures generally give different results. Because the trimean includes the median, it reflects the center of the data as well as the spread between the quartiles.
Does the trimean resist outliers?
Yes. The trimean depends only on the quartiles, so extreme values shift it much less than the mean. A single very large or very small value can move the mean a lot, but it leaves the quartiles and median largely unchanged, and therefore leaves the trimean largely unchanged as well.
What quartiles does this calculator use?
This calculator uses linear interpolation on the sorted data, the type-7 convention shared with the interquartile range calculator. That means the quartiles shown here match the ones you would get from the interquartile range tool, so results from the two pages can be compared directly without adjusting for a different method.