Mean, Median, Mode, Range Calculator

This interactive calculator computes the mean, median, mode, and range from your dataset. It’s built for students, educators, data analysts, and professionals who need fast, accurate, and accessible descriptive statistics.

Authoritative Data Source and Methodology

Primary references:

Tutti i calcoli si basano rigorosamente sulle formule e sui dati forniti da questa fonte.

The Formulas Explained

Mean (arithmetic average):
\\[ \\bar{x} = \\frac{1}{n}\\sum_{i=1}^{n} x_i \\]

Median (middle value in ordered data):
For odd n: \\[ \\tilde{x} = x_{\\left(\\frac{n+1}{2}\\right)} \\] For even n: \\[ \\tilde{x} = \\frac{x_{\\left(\\frac{n}{2}\\right)} + x_{\\left(\\frac{n}{2}+1\\right)}}{2} \\]

Mode (most frequent value(s)):
\\[ \\operatorname*{Mode} = \\operatorname*{arg\\,max}_v f(v) \\]

Range:
\\[ R = \\max(x) - \\min(x) \\]

Glossary of Inputs and Results

Data values
List of numbers separated by commas, spaces, tabs, or new lines. Accepts negatives and decimals.
Decimal places
Chosen precision applied to displayed results (0–8).
Sort option
How the dataset is displayed in the results area: none, ascending, or descending.
Count (n)
Number of valid numeric values parsed from your input.
Sum
Total of all values in the dataset.
Mean
Arithmetic average of the dataset.
Median
Middle value when the data are ordered; average of two middle values if n is even.
Mode
Value(s) with the highest frequency. If all values are unique, there is no mode.
Range
Difference between the maximum and the minimum values.
Minimum / Maximum
The smallest and largest values in the dataset.

How It Works: A Step-by-Step Example

Suppose you enter the dataset: 2, 3, 5, 5, 6, 7, 8.

  1. Sort the data (ascending): 2, 3, 5, 5, 6, 7, 8.
  2. Count: n = 7; Sum = 2 + 3 + 5 + 5 + 6 + 7 + 8 = 36.
  3. Mean: \\( \\bar{x} = 36/7 \\approx 5.142857 \\) → 5.14 (2 decimals).
  4. Median: n is odd, middle value is the 4th item → 5.
  5. Mode: value with highest frequency → 5 (appears twice).
  6. Range: max − min = 8 − 2 = 6.

Frequently Asked Questions (FAQ)

FAQ list

1) Which separators can I use for input data?

Commas, spaces, tabs, and new lines are supported. The tool auto-detects them.

2) How are multiple modes handled?

If multiple values share the highest frequency, the calculator reports each of them (multimodal).

3) What happens to text mixed with numbers?

By default, stray text tokens are ignored. The “Notes” area will list anything skipped so you can correct it if needed.

4) How many decimal places are supported?

You can select from 0 to 8 decimal places. Results use standard rounding to the chosen precision.

5) Does sorting affect the calculations?

Sorting only affects how values are displayed. It does not change the computed statistics.

6) Can I copy the results?

Yes. Use the “Copy results” button to copy a clean, plain-text summary to your clipboard.

7) Is this calculator based on authoritative sources?

Yes. Definitions and formulas align with the NIST/SEMATECH e-Handbook of Statistical Methods and OpenStax Introductory Statistics.

Tool developed by Ugo Candido. Content reviewed by the CalcDomain Editorial Team.
Last reviewed for accuracy on: .