What is variance?

Variance is a mathematical measurement of dispersion. In other words it shows how numbers are spread from their average. Variance is used mostly in hypothesis testing, descriptive statistics, goodness of fit, statistical inference and Monte Carlo sampling. Also variance is square of the satandard deviation.

How to calculate variance?

Population variance and sample variance are calculated differently.

Population variance

σ2=i=1Nxi-μ2N

Sample variance

s2=i=1nxi-x¯2n-1