Mean, Median, Mode Calculator
Data set · Weighted average · Grouped data · Score needed
📊 Enter a list of numbers to see the mean, median, mode, and range with steps.
What Are Mean, Median, and Mode?
Mean, median, and mode are the three common measures of the center of a data set, often called averages. The mean is the sum of the values divided by how many there are. The median is the middle value after sorting, so half the data lie below it and half above. The mode is the value that appears most often.
The range, the largest value minus the smallest, is usually reported alongside them to show spread. For the 20 exam scores in the calculator, the mean is 1,460 ÷ 20 = 73, the median is 72, the mode is 72 (five students), and the range is 93 − 50 = 43.
How to Use the Mean, Median, Mode Calculator
- Data: paste or type numbers separated by commas, spaces, or new lines. You get the mean, median, mode, range, midrange, geometric mean, and a 10% trimmed mean, plus a frequency table.
- Weighted: enter one value and its weight per line, such as a grade and its percentage of the course. Frequencies work the same way: "4, 5" means the value 4 appears five times.
- Grouped: enter class intervals such as "20 to 30, 12" when you only have a frequency table, not the raw values. The calculator estimates all three averages.
- Score needed: enter your scores so far, the average you want, and how many scores remain. It shows the score you need on each remaining test.
Mean, Median, and Mode Formulas
Which Average Should You Use?
| Data | Best measure |
|---|---|
| Roughly symmetric, no outliers | Mean |
| Incomes, house prices, wait times | Median |
| Data with a few extreme values | Median or trimmed mean |
| Categories (colors, shoe sizes) | Mode |
| Grades with different weights | Weighted mean |
| Growth rates, ratios | Geometric mean |
| Only a frequency table | Grouped estimates |
How to Find the Mean, Median, and Mode Manually
- Sort the values from smallest to largest.
- Mean: add all values and divide by the count n.
- Median: find position (n + 1) ÷ 2. With an odd count it is a single value; with an even count, average the two middle values.
- Mode: count how often each value occurs and pick the most frequent.
- Range: subtract the minimum from the maximum.
Odd count example: 4, 9, 2, 7, 9 sorts to 2, 4, 7, 9, 9. The mean is 31 ÷ 5 = 6.2, the median is the third value, 7, the mode is 9, and the range is 9 − 2 = 7.
Mean vs Median for Skewed Data
The mean is pulled toward the long tail of a skewed distribution. When the right tail is heavier, the mean is greater than the median; when the left tail is heavier, the mean is smaller.
In a town where 49 people earn $30,000 and one earns $5,000,000, the mean income is $129,400 but the median is $30,000. A trimmed mean, which drops a set share of the lowest and highest values before averaging, is a middle ground: it keeps more of the data than the median but resists outliers.
No Mode, Bimodal, and Multimodal Data
- No mode: every value appears equally often, as in 4, 7, 9, 12.
- Unimodal: one value is most frequent, as with 72 in the exam scores.
- Bimodal: two values tie, as in 430, 430, 480, 480, 495.
- Multimodal: three or more values tie for the top frequency.
Two modes can signal two groups mixed together, such as the heights of adults and children.
Weighted Average
A weighted average gives some values more influence than others. Multiply each value by its weight, add the products, and divide by the total weight. A course where homework (90) counts 20%, the midterm (78) 30%, and the final (85) 50% gives a grade of 83.9, not the simple average of 84.33.
The same formula turns a frequency table into a mean. If the value 1 appears 3 times, 2 appears 2 times, 3 once, and 4 five times, the mean is (3 + 4 + 3 + 20) ÷ 11 = 2.7273. The weighted median is the value where the running total of weights first reaches half of the total weight.
Mean, Median, and Mode of Grouped Data
When data are only available as class intervals with frequencies, the exact values are unknown, so each average is an estimate.
Worked example (the calculator default): classes 0 to 10, 10 to 20, 20 to 30, 30 to 40, and 40 to 50 with frequencies 5, 8, 12, 7, 3, so n = 35.
- Mean: (5×5 + 15×8 + 25×12 + 35×7 + 45×3) ÷ 35 = 825 ÷ 35 = 23.571.
- Median: n ÷ 2 = 17.5. The cumulative frequencies are 5, 13, 25, so the median class is 20 to 30 with F = 13 and f = 12. Median = 20 + (4.5 ÷ 12) × 10 = 23.75.
- Mode: the modal class is 20 to 30 with f₁ = 12, f₀ = 8, f₂ = 7. Mode = 20 + (4 ÷ 9) × 10 = 24.444.
If classes are written with gaps, such as 1 to 10 and 11 to 20, the true boundaries lie halfway between, at 10.5. The calculator detects gaps and uses those boundaries automatically.
What Score Do I Need for a Target Average?
Needed total = target average × total number of scores. Subtract the sum you already have, then divide by the number of scores remaining.
With 82, 75, 90, and 68 (sum 315) and a target of 80 across five tests, you need 80 × 5 − 315 = 85 on the last test. With two tests left the total needed is 80 × 6 − 315 = 165, an average of 82.5 on each. If the answer is above the maximum score, the target is out of reach. This assumes every score counts equally.
Common Mistakes
- Forgetting to sort. The median of 9, 2, 7 is 7, not the middle entry 2.
- Using (n + 1) ÷ 2 as the median. It is the position, not the value. For n = 20 it points between the 10th and 11th values.
- Averaging averages. Two classes with means of 70 (10 students) and 90 (30 students) have a combined mean of 85, not 80. Use a weighted mean.
- Dropping zeros. A zero is a real value and lowers the mean; a blank is missing data.
- Reporting the mode for continuous data. With precise measurements every value may be unique, so a grouped mode is more meaningful.
Frequently Asked Questions
Sources & References
- NIST/SEMATECH. Engineering Statistics Handbook, 1.3.5.1 Measures of Location itl.nist.gov
- OpenStax. Introductory Statistics 2e, 2.5 Measures of the Center of the Data openstax.org
- University of Massachusetts Amherst. BIEP 540W Lecture 2, Grouped Data Calculation people.umass.edu
Results are for educational use. Grouped values are estimates. Methodology reviewed: 2026.