... LIVE
📊 Enter Your Data
📌 Enter values separated by commas, spaces, or new lines. Works with any paste from Excel, Google Sheets, or a list. Minimum 2 values required.
Separate with commas, spaces, or new lines — decimals and negative numbers supported
Please enter at least 2 valid numbers.
Arithmetic Mean
⚠️ Disclaimer: Results are for educational and informational purposes. Verify critical statistical calculations with a qualified statistician.

Sources & Methodology

All formulas follow standard statistical definitions verified against multiple authoritative textbooks and NIST standards.
📘
NIST/SEMATECH e-Handbook of Statistical Methods
Section 1.3.5 Measures of Location — definitive reference for mean, median, mode, and midrange definitions and computational methods.
📙
Moore, D.S., McCabe, G.P. & Craig, B.A. — Introduction to the Practice of Statistics (9th ed.)
Standard introductory statistics textbook used at hundreds of universities worldwide. Reference for median calculation procedures for odd and even n, mode definition, and range formulas.
📊
Lax, D.A. (1988) — Robust Estimators of Scale
Foundation paper for median absolute deviation as a robust measure of spread, and its comparison with mean absolute deviation for skewed and contaminated distributions.
Formulas used:
Mean = ∑x⊂i; / n Median = middle value (odd n) or average of two middle values (even n), after sorting Mode = most frequent value(s) | Range = max − min | Midrange = (max + min) / 2 MAD (from mean) = ∑|x⊂i;−mean| / n | MAD (from median) = median of |x⊂i;−median| MSE = ∑(x⊂i;−mean)² / n Sorted order: ascending. Median highlighted in sorted display. Mode values highlighted. Step-by-step working shown for all measures.

Mean, Median, Mode — Complete Guide with All Formulas

Mean, median, and mode are the three measures of central tendency — they describe where the center of a dataset lies. Alongside these, range, midrange, mean absolute deviation (MAD), and median absolute deviation give you the spread. Together, these eight measures give you a complete picture of any dataset without needing advanced statistics.

How to Calculate the Mean (Arithmetic Average)

The mean is simply the sum of all values divided by how many values there are. It uses every data point, which makes it the most informative measure of center for symmetric data but also the most sensitive to outliers.

Mean (x̅) = (x⊂1; + x⊂2; + … + x⊂n;) / n = ∑x / n
Example: Dataset: 3, 7, 5, 9, 1, 5, 8
Sum = 3+7+5+9+1+5+8 = 38   |   n = 7   |   Mean = 38/7 = 5.43

How to Find the Median (Middle Value)

The median is found by sorting all values and finding the middle one. Unlike the mean, the median ignores how extreme the highest and lowest values are — only their rank (position) matters. This makes it ideal for skewed data like incomes, house prices, or response times.

If n is odd: median = value at position (n+1)/2 in sorted list If n is even: median = average of values at positions n/2 and (n/2)+1
Odd example (n=5): Sorted: 2, 4, 7, 9, 12 → Median = 7 (position 3)
Even example (n=6): Sorted: 2, 4, 7, 9, 12, 15 → Median = (7+9)/2 = 8

How to Find the Mode (Most Frequent Value)

The mode is the value that appears most often. A dataset can have one mode (unimodal), two modes (bimodal), three or more modes (multimodal), or no mode if every value appears exactly once. Mode is the only measure of central tendency applicable to categorical data (like “which color was chosen most?”).

Mode = value(s) with the highest frequency count
Single mode: 2, 3, 4, 4, 5, 6 → Mode = 4 (appears twice)
Bimodal: 1, 2, 2, 3, 4, 4, 5 → Modes = 2 and 4
No mode: 1, 2, 3, 4, 5 → No mode (all appear once)

Mean vs Median — When to Use Each

This is the most important practical decision in descriptive statistics. The answer depends on the shape of your data and whether outliers are present.

SituationUse MeanUse MedianWhy
Symmetric, no outliersEither worksMean uses all info; both give same result
Right-skewed (income, prices)Outliers pull mean far above typical value
Left-skewed (test scores near 100)Low outliers pull mean below typical value
Outliers presentMedian is resistant to extreme values
Categorical dataUse mode — mean/median require numeric order
Further calculations (std dev, CI)Mean is foundation of most statistical tests

Range and Midrange — Simplest Spread Measures

Range = maximum − minimum. The simplest measure of spread. Highly sensitive to outliers since it only uses the two extreme values. Midrange = (max + min) / 2. Estimates the center using only the extremes. For symmetric data, midrange ≈ mean ≈ median. For skewed data, they diverge significantly.

Mean Absolute Deviation (MAD) vs Standard Deviation

MAD measures average spread around the mean using absolute values, while standard deviation uses squared deviations. MAD is more robust to outliers because outliers are penalized linearly (not squared). Standard deviation penalizes large deviations much more heavily, making it more sensitive but also more mathematically tractable for further analysis.

MAD (from mean) = ∑|x⊂i; − mean| / n MAD (from median) = median of {|x⊂1;−median|, |x⊂2;−median|, …, |x⊂n;−median|}
Example: Dataset: 2, 4, 4, 4, 5, 5, 7, 9   Mean = 5
Absolute deviations from mean: 3, 1, 1, 1, 0, 0, 2, 4   Sum = 12
MAD from mean = 12/8 = 1.5
Median = (4+5)/2 = 4.5. Sorted |deviations from median|: 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 2.5, 4.5
Median absolute deviation = 0.5

The Relationship Between Mean, Median, and Skewness

The relative positions of mean, median, and mode reveal the distribution’s shape:

Pearson’s skewness coefficient = 3 × (mean − median) / standard deviation. A value near 0 indicates symmetry. Values beyond ±1 indicate significant skewness affecting which central tendency measure is most appropriate.

💡 Real-world context: The US Census Bureau reports median household income, not mean income, specifically because the income distribution is heavily right-skewed. A few extremely high-income households pull the mean far above what a typical household earns. The median gives a more accurate picture of the “typical” household. The same principle applies whenever you see “typical” or “representative” values — reach for the median first.

Mean Squared Error (MSE) — Connection to Variance

MSE from the mean equals the population variance (divides by n, not n−1). It measures the average squared distance of values from the mean. MSE is the basis of ordinary least squares regression — fitting a regression line minimizes the MSE. It penalizes large deviations much more heavily than MAD, making it sensitive to outliers but powerful for optimization problems.

MSE = ∑(x⊂i; − mean)² / n = population variance (σ²) RMSE = √MSE = population standard deviation (σ)
Note: this calculator computes MSE from the dataset mean. In regression contexts, MSE = ∑(actual − predicted)² / n.
Frequently Asked Questions
Add all values together and divide by the count. Mean = ∑x / n. Example: dataset 3, 7, 5, 9, 1 → sum = 25, n = 5, mean = 25/5 = 5. The mean uses every value, making it the most comprehensive but also the most sensitive to outliers. One very large or small value can shift the mean significantly.
First sort all values smallest to largest. For odd n: median = value at position (n+1)/2. For even n: median = average of values at positions n/2 and n/2+1. Odd example (n=5): sorted data 2, 4, 7, 9, 12 → median = 7. Even example (n=6): sorted 2, 4, 7, 9, 12, 15 → median = (7+9)/2 = 8. The median is always in the exact middle of the sorted list.
Count how often each unique value appears. The mode is the value with the highest count. If all values appear equally often, there is no mode. If two values tie for highest count, both are modes (bimodal). Example: 1, 2, 2, 3, 4, 4, 5 → modes are 2 and 4 (both appear twice, bimodal). Mode is the only central tendency measure valid for categorical data like survey responses or colors.
Mean = arithmetic average (sum/n) — uses every value, sensitive to outliers. Median = middle value when sorted — resistant to outliers, best for skewed data. Mode = most frequent value — not affected by outliers, only measure for categorical data. For symmetric distributions (like a bell curve), all three are approximately equal. For right-skewed data (income): mode < median < mean. Always report which you used and why.
Use mean for symmetric, normally distributed data without extreme outliers — it uses all available information. Use median for skewed data (income, house prices, response times, survival times) or when outliers are present. The rule of thumb: if mean and median are very close, either is fine. If they differ significantly, the distribution is skewed and median is more representative of the typical value. Government agencies report median income for exactly this reason.
Midrange = (maximum + minimum) / 2. It is the simplest estimate of center but highly sensitive to extreme values since it ignores all data except the two endpoints. Example: 3, 5, 7, 9, 100 → midrange = (3+100)/2 = 51.5, which is far higher than the mean (24.8) or median (7). Midrange is taught in elementary statistics but rarely used in professional work because of its extreme sensitivity to outliers.
MAD from mean = ∑|x⊂i;−mean| / n. Steps: (1) find the mean, (2) subtract mean from each value and take the absolute value, (3) sum all absolute deviations, (4) divide by n. Example: dataset 2, 4, 4, 4, 5, 5, 7, 9, mean = 5. Absolute deviations: 3, 1, 1, 1, 0, 0, 2, 4. Sum = 12. MAD = 12/8 = 1.5. MAD is more robust to outliers than standard deviation.
Mean absolute deviation uses the mean as center and averages the deviations. Median absolute deviation uses the median as center and takes the median of the deviations. Median absolute deviation is more robust to outliers than both MAD and standard deviation because it uses two resistant measures (median + median). Formula: median of |x⊂i;−median|. Used in robust statistics for outlier detection: common threshold is values more than 2.5 times the median absolute deviation from the median.
Outliers strongly pull the mean toward them. Example: 1, 2, 3, 4, 100 → mean = 22 (far from most values). Median = 3 (unaffected). Mode = no mode. This is why the mean can be misleading for skewed data. A single billionaire in a group of 100 average-income people dramatically increases the mean income but leaves the median unchanged. Always check if mean and median differ significantly — a big gap means outliers are affecting the mean.
Yes to all three. No mode: 1, 2, 3, 4, 5 (all appear once — amodal). One mode (unimodal): 1, 2, 2, 3, 4 → mode = 2. Two modes (bimodal): 1, 2, 2, 3, 4, 4, 5 → modes = 2 and 4. Multiple modes (multimodal): 1, 1, 2, 2, 3, 3 → modes = 1, 2, and 3. A bimodal distribution often indicates two distinct subgroups in your data (e.g., heights of men and women combined).
Symmetric distribution: mean = median = mode. Right-skewed (positive): mode < median < mean (the tail pulls the mean right). Left-skewed (negative): mean < median < mode (the tail pulls the mean left). Pearson’s skewness coefficient = 3×(mean−median)/std dev. A value of 0 means symmetric. Greater than 1 or less than −1 indicates substantial skewness that makes the median a better measure of center than the mean.
MSE = ∑(x⊂i;−mean)² / n. This is exactly the population variance (σ²) when computed from the dataset mean. MSE penalizes large deviations more than MAD because deviations are squared. It is the basis of ordinary least squares (OLS) regression — fitting the best line minimizes MSE. RMSE (root MSE) = √MSE = population standard deviation. Sample variance uses n−1 denominator; MSE as computed here uses n.
Related Statistics Calculators
Popular Calculators
🧮

Missing a Statistics Calculator?

Can’t find the statistical tool you need? Tell us — we build new calculators every week.