keencalculator
  1. Home
  2. Statistics
  3. Variance Calculator

Variance Calculator

Enter a data set to calculate its variance, the average squared distance from the mean. Both the sample variance (dividing by n − 1) and the population variance (dividing by n) are shown, along with the mean, the sum of squares and both standard deviations.

Quick examples

Separate values with commas, spaces or new lines.

Your numbers stay in your browser. Nothing is uploaded.
Sample variance (s²)9.3333

Divides by n − 1.

Population variance (σ²)
8
Mean
9
Count (n)
7
Sum of squared deviations
56
Sample standard deviation (s)
3.0551
Population standard deviation (σ)
2.8284

Saved setups

Save a set of inputs you reuse — your usual rate, your loan, your room sizes — and load it back in one tap.

    Your recent calculations

    Results you calculate here are kept on this device so you can come back to them.

      Formula

      Sample variance s² = Σ(x − x̄)² ÷ (n − 1)
      Population variance σ² = Σ(x − x̄)² ÷ n
      Standard deviation = √variance

      How to use it

      1. Type or paste your data, separated by commas, spaces or new lines.
      2. Read the sample variance if the data is a sample, or the population variance if it is the whole group.
      3. Take the standard deviation if you want the spread in the original units.

      Worked examples

      The data set 6, 9, 14, 10, 5, 8, 11

      Sample variance (s²)
      9.3333
      Population variance (σ²)
      8
      Mean
      9
      Count (n)
      7
      Sum of squared deviations
      56
      Sample standard deviation (s)
      3.0551

      The six faces of a die

      Sample variance (s²)
      3.5
      Population variance (σ²)
      2.9167
      Mean
      3.5
      Sum of squared deviations
      17.5

      A worked example

      For 6, 9, 14, 10, 5, 8, 11 the mean is 9. The deviations are −3, 0, 5, 1, −4, −1 and 2; squared, they are 9, 0, 25, 1, 16, 1 and 4, which total 56. The sample variance is 56 ÷ 6 = 9.333 and the population variance is 56 ÷ 7 = 8.

      Variance versus standard deviation

      Variance is in squared units — square dollars, square inches — which makes it hard to picture. Its square root, the standard deviation, is back in the original units and is the one usually quoted.

      Variance is the one to use in calculations, though: the variances of independent quantities add, while standard deviations do not. In Excel and Google Sheets the functions are VAR.S and VAR.P.

      Questions people ask

      What is the variance of 6, 9, 14, 10, 5, 8, 11?

      The sample variance is 9.333 and the population variance is 8.

      What is the variance of a fair six-sided die?

      35/12, about 2.917. Entering 1 through 6 gives this as the population variance.

      Why divide by n − 1 for a sample?

      Deviations are measured from the sample’s own mean, which sits closer to the data than the true mean does. Dividing by n − 1 corrects the resulting underestimate.

      Related calculators