Statistics Calculator: Mean, Median, Mode and More
The calculator for this page is switched off while it is checked. The formula is below, and the worked example in the article shows how to use it by hand.
A statistics calculator summarizes a list of numerical data, returning measures such as the mean, median, mode, range, variance, and standard deviation. Enter your values as a comma-separated list to see the results; the example below uses a built-in list so you can check how the calculations work.
Formula
The calculator applies standard descriptive-statistics formulas to the values in the list. Let the data be x1, x2, …, xn, where n is the number of observations.
- Mean: x̄ = (x1 + x2 + … + xn) / n. Add all values and divide by the count.
- Median: Sort the values. For an odd count, take the middle value; for an even count, average the two middle values.
- Sample standard deviation: s = √[Σ(xi − x̄)² / (n − 1)]. It measures spread around the mean when the data are treated as a sample.
- Range: maximum value − minimum value.
All four outputs use the same unit as the entered data, except that variance—if calculated separately—uses squared units. The sample standard deviation is shown here because it is a common estimate of spread from sample data. For a complete population, use population standard deviation instead, whose variance denominator is n.
Worked Example
Using the exact default list, 2, 4, 4, 6, 9:
- Mean: (2 + 4 + 4 + 6 + 9) / 5 = 25 / 5 = 5.00.
- Median: The ordered list is already 2, 4, 4, 6, 9. The middle, third value is 4.00.
- Sample standard deviation: The deviations from 5 are −3, −1, −1, 1, and 4. Their squares total 9 + 1 + 1 + 1 + 16 = 28. Divide by 5 − 1 to get a sample variance of 7; √7 ≈ 2.65.
- Range: 9 − 2 = 7.00.
The displayed values are rounded to two decimal places. Calculations use the underlying values, not the rounded display.
What Statistics Does the Calculator Show?
Descriptive statistics condense a data set into quantities that are easier to compare and interpret. The mean and median describe the center; standard deviation and range describe aspects of spread. They are summaries, not a full account of the data: two lists can share a mean and range but have very different distributions.
- Mean: Uses every observation, so unusually high or low values can pull it away from where most values lie.
- Median: Gives the central position and is less affected by extreme values. It is useful for skewed data, such as a set of incomes.
- Mode: The most frequent value. A data set may have one mode, multiple modes, or no uniquely most frequent value.
- Range: The distance between the smallest and largest observations. It is easy to understand but depends only on those two values.
- Standard deviation: Describes typical distance from the mean in the data’s original units. It is sensitive to outliers and is most informative alongside the mean and distribution shape.
When to Use Each Measure
Choose a summary that fits the question and the data. If measurements are fairly balanced and have no extreme outliers, the mean and standard deviation are often informative together. If data are strongly skewed or contain exceptional values, the median and a measure such as the range may better communicate what is typical. For example, in the list 2, 4, 4, 6, 9, the mean is 5 while the median is 4; the larger value 9 pulls the mean upward.
These calculations apply to numerical observations. A list of category labels such as colors does not have a meaningful arithmetic mean. Likewise, identifiers—student numbers, product codes, or postal codes—may look numeric but are not measurements, so arithmetic summaries of them are generally meaningless.
Entering Data and Avoiding Common Errors
Use one observation per number and check that the list contains only the values you intend to summarize. Before interpreting the result, consider these common issues:
- Mixing units: Convert measurements to one unit first. Combining centimeters and inches directly makes the mean, standard deviation, and range meaningless.
- Confusing a sample with a population: Sample standard deviation divides the sum of squared deviations by n − 1; population standard deviation divides by n. Choose according to what the observations represent.
- Rounding too early: Keep full precision in intermediate steps and round only the final display. Early rounding can shift a result.
- Ignoring missing or unusual values: Check whether a blank, transcription error, or extreme observation is legitimate. Do not remove a real observation solely because it changes the answer.
- Misreading the range: Range is a difference, not the interval itself. For values from 2 to 9, the range is 7.
Limits and Interpretation
A calculator can perform arithmetic accurately, but it cannot determine whether the sample represents a larger population, whether the data were collected fairly, or whether a result has practical importance. Those judgments depend on study design and subject knowledge. Descriptive statistics also do not establish cause and effect.
Standard deviation has a familiar interpretation for roughly symmetric, bell-shaped distributions: many observations lie within about one standard deviation of the mean. That rule is not guaranteed for every data set, and it can mislead when values are skewed, clustered, or dominated by outliers. Inspecting a plot or the sorted observations can reveal patterns that a few summary numbers hide.
For a full population, calculate population standard deviation rather than using the sample formula shown in the calculator. For comparing groups with different units or substantially different scales, a raw standard deviation may not be directly comparable; consider whether a standardized measure is appropriate for the question.
Frequently Asked Questions
What is the difference between mean and median?
The mean is the sum divided by the number of values. The median is the middle value after sorting, or the average of the two middle values when the count is even. Extreme values affect the mean more strongly.
Should I use sample or population standard deviation?
Use sample standard deviation when your observations are a sample used to estimate variability in a larger group. Use population standard deviation when your list contains the entire population of interest.
Can a data set have more than one mode?
Yes. If two or more values tie for the highest frequency, the data may be multimodal. If every value appears equally often, there may be no single useful mode.
Can I calculate statistics for negative numbers?
Yes. Negative observations are valid for many measurements, such as changes relative to a baseline or temperatures on scales that allow values below zero. The list’s meaning determines whether those values make sense.
Why do my results differ from another calculator?
Check whether both tools use sample or population standard deviation, handle missing values the same way, and display the same rounding precision. The mean and median should agree when the input list is identical and processed consistently.
Related
Formula used
list values | Data values | 2, 4, 4, 6, 9 out mean | Mean | - | mean(values) | 2 out median | Median | - | median(values) | 2 out sd | Sample standard deviation | - | sd(values) | 2 out range | Range | - | range(values) | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.