How to use the average calculator
- Type or paste your numbers, separated by spaces, commas or new lines. Decimals and negative numbers are fine.
- The mean (what most people call the average) appears at once, with the median, mode, range, sum, smallest and largest values and two kinds of standard deviation.
- Switch to Weighted average when some values count for more than others, such as exam components with different percentages. Enter one line per item as
value, weight.
Leave out thousands separators (write 1200, not 1,200) because commas separate the numbers.
Mean, median and mode: which average to use
| Measure | How it is found | Best for | Weakness |
|---|---|---|---|
| Mean | Add all values and divide by how many there are | Symmetric data such as test scores, temperatures | One extreme value pulls it up or down |
| Median | The middle value once sorted (average of the middle two if the count is even) | Incomes, house prices, anything with outliers | Ignores how far the other values are |
| Mode | The value that appears most often | Categories and popular sizes, e.g. the most common shoe size | May not exist, or there may be several |
| Geometric mean | The nth root of the product of n positive values | Growth rates, ratios, returns over time | Needs all values above zero |
Formulas
mean = (x₁ + x₂ + … + xₙ) ÷ n weighted mean = Σ(value × weight) ÷ Σ(weight) population standard deviation = √( Σ(x − mean)² ÷ n ) sample standard deviation = √( Σ(x − mean)² ÷ (n − 1) )
Use the sample standard deviation when your numbers are a sample drawn from a larger group, which is the usual case in surveys and experiments. Use the population version when your numbers are the whole group, for example every score in one small class. The sample version divides by n − 1 to correct for the fact that a sample tends to understate the spread.
Worked example
Six test scores: 12, 15, 11, 15, 20, 18.
- Sum: 12 + 15 + 11 + 15 + 20 + 18 = 91
- Mean: 91 ÷ 6 = 15.1667
- Median: sorted they are 11, 12, 15, 15, 18, 20. With six values the median is the average of the 3rd and 4th, (15 + 15) ÷ 2 = 15
- Mode: 15 appears twice and every other value once, so the mode is 15
- Range: 20 − 11 = 9
- Standard deviation: the squared differences from the mean add up to 58.8333, giving a population value of 3.1314 (÷ 6) and a sample value of 3.4303 (÷ 5)
Weighted example. A course is graded 30% coursework (80), 50% exam (90) and 20% project (70). The weighted average is (80 × 30 + 90 × 50 + 70 × 20) ÷ 100 = 83. A plain mean of 80, 90 and 70 would give 80, which understates the exam. With credit-hour weights, grades of 85 (4 credits), 90 (3) and 72 (2) give (340 + 270 + 144) ÷ 9 = 83.78.
When the average misleads
- Outliers: in the list 20, 22, 21, 23, 200 the mean is 57.2, which describes no one in the group, while the median of 22 is typical.
- Percentages of different sizes: averaging 50% of 10 people and 10% of 1,000 people as 30% is wrong. Weight by group size instead.
- Rates and speeds: driving 60 km/h out and 40 km/h back averages 48 km/h (the harmonic mean), not 50.
- Growth: a gain of 50% followed by a loss of 50% is a 25% loss overall, so an arithmetic mean of 0% hides it. Use the geometric mean for growth factors.
Accuracy and limits
Calculations use standard double-precision numbers and are shown to six decimal places, trimmed. Very large lists of several hundred thousand numbers work but may take a moment to type or paste. The geometric mean needs every number above zero and shows "n/a" otherwise. Standard deviation needs at least two numbers in its sample form.
Frequently asked questions
What is the difference between mean, median and mode?
The mean is the sum divided by the count, the median is the middle value in sorted order, and the mode is the most frequent value. They answer different questions and can all differ for the same data.
How do I calculate a weighted average?
Multiply each value by its weight, add the results and divide by the total of the weights. The weights can be percentages, credits or counts.
Why does the calculator show two standard deviations?
The population version divides by n and suits a complete group. The sample version divides by n − 1 and suits a sample from a bigger group. If you are unsure, the sample version is the safer choice.
Can there be more than one mode?
Yes. If two or more values tie for the most appearances, they are all modes. If every value appears once, there is no mode.
How do I average percentages?
Only average them directly if each percentage is based on the same size group. Otherwise use the weighted average with the group sizes as weights.