Trimmed Mean Calculator
Average a data set after dropping a chosen share from both tails.
What it does
The ordinary mean is easy to compute but easy to distort. One very large or very small value can move it a long way. A trimmed mean reduces that sensitivity by removing a chosen share of the smallest and largest values before averaging what remains.
This tool sorts the data, drops the requested percentage from each tail, and reports the mean of the survivors. It also prints the ordinary mean and the number of values kept, so the effect of the trimming is visible.
A common choice is to trim five or ten percent from each end. The result then behaves between the mean, which uses every value, and the median, which uses only the middle. That middle ground is useful when data contain occasional gross errors or heavy tails.
Trimming is a deliberate loss of information. If the extremes are genuine and important, removing them hides real variation. Choosing the percentage should be part of the analysis, not an afterthought made to get a preferred answer.
How to use
- Enter the values separated by commas or spaces.
- Set the percentage to remove from each tail.
- Read the trimmed mean in the main result.
- Compare it with the ordinary mean shown below.
- Check how many values were kept.
- Try a few trim levels to see how stable the centre is.
Formula
- n
- Number of values supplied.
- p
- Percentage removed from each tail.
- k
- Count dropped from each end, rounded down to a whole number.
Values are sorted before anything is removed, so the order you type them in does not matter. The count removed from each end is rounded down, which means the actual trim can be a little below the requested percentage for small samples. A 0 percent trim reproduces the ordinary mean exactly. The tool refuses a trim that would remove every value, which would leave nothing to average.
Worked example
Example: a 10 percent trim of ten values
Values 1, 2, 2, 3, 4, 5, 6, 8, 10, 100 with a 10 percent trim.
- There are ten values, so 10 percent is one value per tail.
- Remove the smallest value 1 and the largest value 100.
- Eight values remain: 2, 2, 3, 4, 5, 6, 8, 10.
- Their sum is 40, so the trimmed mean is 40 / 8 = 5.
- The ordinary mean is 141 / 10 = 14.1.
- Tool shows 5, an ordinary mean of 14.1, and 8 kept.
Reference table
| Trim each tail | Values kept | Trimmed mean | Ordinary mean |
|---|---|---|---|
| 0 % | 10 | 14.1 | 14.1 |
| 10 % | 8 | 5 | 14.1 |
| 20 % | 6 | 4.666667 | 14.1 |
| 30 % | 4 | 4.5 | 14.1 |
| 40 % | 2 | 4.5 | 14.1 |
Limits
- Trimming discards information, which matters if extremes are real.
- Rounding the tail count down makes small samples trim less than requested.
- The choice of percentage is subjective.
- The result still depends on the values that remain.
Common mistakes
- Removing values before sorting the data.
- Trimming 10 percent in total rather than from each tail.
- Using a trim so large that no values remain.
- Calling the result the median when it is a mean of survivors.
- Picking the trim level only after seeing which answer looks best.
Try it yourself
Quick checks. Answers sit tucked under each question.
Ten values with a 10 percent trim: how many are removed in total?
Two, one from each end.
For the example data, what is the trimmed mean?
40 / 8 = 5.
What is a 0 percent trimmed mean?
The ordinary mean, because nothing is removed.
Questions
What is a trimmed mean?
A mean calculated after dropping a share of the smallest and largest values.
Why use one?
It is less sensitive to outliers than the ordinary mean.
What trim level is common?
Five or ten percent from each tail.
Is a 10 percent trim the same as dropping 10 percent in total?
No. It removes 10 percent from each end, or 20 percent of the data.
Does typing order matter?
No. The tool sorts the values first.
How is it different from a Winsorized mean?
Winsorizing replaces extremes instead of removing them.
Sources
- NIST/SEMATECH e-Handbook: Measures of Location
- University of Minnesota Stat 3011: Mean, Median and Trimmed Mean