Ad Space — Top Banner

Variance Formula

Calculate variance with σ² = Σ(x - μ)² / N.
Understand how much data values deviate from the mean on average.

The Formula

Population: σ² = Σ(x - μ)² / N
Sample: s² = Σ(x - x̄)² / (n - 1)

Variance measures the average of squared differences from the mean. It tells you how spread out your data is. Variance is simply the standard deviation squared.

Variables

SymbolMeaning
σ²Population variance
Sample variance
xEach individual data value
μPopulation mean
Sample mean
NPopulation size
n - 1Degrees of freedom (for sample data)

Example 1 — Population Variance

Find the variance of: 2, 4, 6, 8, 10 (entire population)

Step 1: Find the mean — μ = (2 + 4 + 6 + 8 + 10) / 5 = 30 / 5 = 6

Step 2: Squared differences:

(2 - 6)² = 16, (4 - 6)² = 4, (6 - 6)² = 0, (8 - 6)² = 4, (10 - 6)² = 16

Step 3: Sum = 16 + 4 + 0 + 4 + 16 = 40

Step 4: Divide by N — 40 / 5 = 8

σ² = 8 — The average squared deviation from the mean is 8.

Example 2 — Sample Variance

Heights (in cm) from a sample: 160, 165, 170, 175, 180

Step 1: Find the mean — x̄ = (160 + 165 + 170 + 175 + 180) / 5 = 850 / 5 = 170

Step 2: Squared differences:

(160 - 170)² = 100, (165 - 170)² = 25, (170 - 170)² = 0, (175 - 170)² = 25, (180 - 170)² = 100

Step 3: Sum = 100 + 25 + 0 + 25 + 100 = 250

Step 4: Divide by (n - 1) — 250 / 4 = 62.5

s² = 62.5 — The sample variance is 62.5 cm².

When to Use It

Use the variance formula when:

  • You need a precise numerical measure of data spread
  • Performing advanced statistical tests that require variance (like ANOVA)
  • Comparing the variability of two or more data sets
  • Calculating standard deviation (just take the square root of variance)

Ad Space — Bottom Banner

Embed This Calculator

Copy the code below and paste it into your website or blog.
The calculator will work directly on your page.