Calculator · Level 2

Mean, median, mode and range calculator with standard deviation

Paste or type your numbers and get the mean, median, mode and range at once, with every step. The calculator also gives the quartiles, the interquartile range, the population and sample standard deviation, outliers, a frequency table and a box plot.

Also available in: Deutsch · Português · Español

Free for teaching and learning (terms (in German)). Ad-free in class: Classroom view · Do you teach?

How to use the calculator

Type your data into the box, separated by commas, spaces, semicolons or line breaks. A column copied from a spreadsheet works as well. Use a decimal point for decimals (2.5).

A comma directly in front of exactly three digits is read as a thousands separator, so 1,200 is one value. The list 1,2,3,4 is four values, because each comma is followed by a single digit. To be on the safe side with large numbers, put a space after each separating comma: 1,200, 1,500, 3,000. If a value occurs several times, you can write 4*3 instead of 4, 4, 4.

Mean, median, mode and range

  • The mean (the average) is the sum of all values divided by the number of values.
  • The median is the middle value after sorting. With an even number of values, it is the mean of the two middle values.
  • The mode is the value that occurs most often. A data set can have several modes, or none if every value occurs only once.
  • The range is the largest value minus the smallest value.

Mean or median? Outliers

The mean reacts strongly to single extreme values, the median hardly at all. Five salaries of $42,000, $45,500, $47,000, $51,000 and $250,000 have a mean of $87,100, but a median of $47,000, which describes the typical salary much better.

The calculator can mark outliers with the 1.5 × IQR rule. The interquartile range IQR is Q₃ − Q₁, and a value counts as an outlier if it lies more than 1.5 × IQR below Q₁ or above Q₃.

Quartiles and the box plot

The quartiles split the sorted data into four parts. The box plot shows the minimum, Q₁, the median, Q₃ and the maximum; the box covers the middle half of the data.

There is more than one rule for quartiles, and different textbooks and calculators can give different results for the same data. This calculator uses the position rule: for Q₁ it computes n × 0.25; if that is not a whole number, it rounds up and takes the value in that position, otherwise it takes the mean of that position and the next one (Q₃ the same way with n × 0.75). Many US classes and the TI-84 use the median of each half instead. For Example 1 both rules give Q₁ = 4 and Q₃ = 8. For 3, 5, 8, 12, 40 the median-of-halves rule gives Q₁ = 4 and Q₃ = 26, while this calculator gives 5 and 12. If your class uses a specific rule, check the quartiles by hand.

Variance and standard deviation

The standard deviation measures how far the values typically lie from the mean. The calculator gives two versions:

  • the population standard deviation σ, which divides by n; use it when your data are the whole group;
  • the sample standard deviation s, which divides by n − 1; use it when your data are a sample from a larger group.

For Example 1 the variance is 58.9 ÷ 10 = 5.89, so σ = √5.89 ≈ 2.4269, and s ≈ 2.5582. The steps show the calculation for σ. The table also lists the mean absolute deviation, the coefficient of variation and, for positive data, the geometric and harmonic means.

Frequently asked questions

How do you find the mean?

Add all the values and divide by how many there are. For 3, 5, 8, 12 and 40 the sum is 68, so the mean is 68 ÷ 5 = 13.6.

What if there are two modes?

Then the data set is bimodal, and the calculator lists both values. For 2, 2, 5, 5, 9 the modes are 2 and 5. If every value occurs only once, there is no mode.

How do I enter the same value many times?

Write the value, an asterisk and the count: 2*3, 5*2, 9 means 2, 2, 2, 5, 5, 9. That data set has the mean 25 ÷ 6 ≈ 4.17 and the median 3.5.

Which standard deviation should I use?

If you have data for every member of the group you are describing, use the population value σ. If your data are a sample and you want to estimate the spread of a larger population, use the sample value s.

Why are my quartiles different from my textbook?

Because several quartile rules are in use. The median and the mean are always the same, but Q₁, Q₃, the IQR and therefore the outliers can differ, especially for small data sets. The section on quartiles above explains the rule this calculator uses.

Keep learning

Spotted a mistake or have a request? Send us a short message and we will take care of it.

Spotted a mistake or have a request?

Your message about the page “Mean, median, mode calculator”. We send the page address along automatically.

Please do not include any other personal data. More in our privacy policy (in German).