onlinecalculator.me

Free online variance calculator

Variance measures how far a set of numbers spreads out from their mean. This calculator gives population or sample variance, standard deviation, median, mode, and range.

Type
About this calculator

How to use

  1. Type or paste your numbers into the text box — commas, spaces, semicolons, and line breaks all work.
  2. Choose Sample (the default) or Population depending on your data.
  3. Variance, standard deviation, mean, median, mode, and range update instantly.
  4. Click “Share with my numbers” to copy a URL that restores your data.

Formulas

Population variance:

σ² = Σ(xᵢ − μ)² / n

Sample variance:

s² = Σ(xᵢ − x̄)² / (n − 1)

Standard deviation: square root of the variance.

Where:

  • μ (or ) = mean
  • n = count of values
  • Σ(xᵢ − μ)² = sum of squared deviations from the mean

Worked example

Data: 2, 4, 4, 4, 5, 5, 7, 9 (n = 8)

  1. Mean = 40 / 8 = 5
  2. Squared deviations: (2−5)²=9, (4−5)²=1 × 3, (5−5)²=0 × 2, (7−5)²=4, (9−5)²=16
  3. Sum of squared deviations = 9 + 3 + 0 + 4 + 16 = 32
  4. Population variance σ² = 32 / 8 = 4 → σ = 2
  5. Sample variance s² = 32 / 7 ≈ 4.5714 → s ≈ 2.138

Notes

  • Sample variance requires at least 2 values; population variance works with 1 or more.
  • Mode shows all values tied for the highest frequency. If no value repeats, mode is listed as “None.”
  • Results are rounded to 8 significant figures.
What is variance?
Variance is the average of the squared differences from the mean. A high variance means values are spread widely; a low variance means they cluster near the mean.
What is the difference between population and sample variance?
Population variance divides the sum of squared differences by n. Sample variance divides by n − 1 (Bessel's correction) to give an unbiased estimate when working with a subset of data.
When should I use population vs. sample variance?
Use population variance when you have data for every member of the group. Use sample variance when your data is a sample drawn from a larger population.
What is standard deviation?
Standard deviation is the square root of variance. It expresses spread in the same units as the original data, making it easier to interpret.
Why does sample variance use n − 1?
Dividing by n − 1 corrects for the fact that a sample tends to underestimate the true population spread. This is called Bessel's correction.
How do I enter my numbers?
Type or paste values separated by commas, spaces, semicolons, or line breaks. Any mix of delimiters works.