# Microsoft Excel formula for variance

According to Microsoft Excel Help:

VAR uses the following formula:

where x is the sample mean AVERAGE(number1,number2,…) and n is the sample size.

Shouldn't it be n, rather than n - 1, in the denominator?

-
@onestop The "statistical-bias" tag is somewhat confusing here. –  chl Oct 18 '10 at 21:57
Perhaps you're right. The guidelines suggest updating tags in light of the the answers as well as the original question, so I was wondering if there was a tag for 'unbiased estimator' or 'unbiasedness', but there wasn't, so i used 'statistical bias' on the grounds that separate tags for flip sides of the same coin seem a bit unecessary, and the guidelines favor reuse of existing tags over creation of new ones. I'm about to fall sleep but I'll take another look at this in the morning. –  onestop Oct 18 '10 at 22:13
I changed statistical-bias to unbiased-estimator. Does that work? –  user28 Oct 19 '10 at 0:14
Fine with me. I've just added this new tag to a few other old posts - what do you think? Also does the "statistical bias" tag still have a place? If so, when would you use it? Is this what the "tag wiki" system is meant to be for? I'm afraid I haven't worked out if or how i can edit that. Maybe we should take this to meta... –  onestop Oct 19 '10 at 7:24
@Skrikant In fact, I didn't think another tag was needed at all, but yours looks better. –  chl Oct 19 '10 at 11:22

Use VARP for the variance you want ("population variance"). VAR is the unbiased estimator for a normally distributed population.

-
VAR is unbiased for any distribution with a finite variance, not just for the normal distribution. –  Rob Hyndman Oct 18 '10 at 21:08
Thanks Rob. That condition was indeed unnecessary. –  whuber Oct 18 '10 at 21:41
Right, whatever variance mean when the distribution is not close to normal ;-) –  mbq Oct 18 '10 at 22:26
@mbq to some, the variance is a moment of inertia. there is also chebyshev's inequality, that applies to any distribution. it also has an interpretation similar to that for the normal for any location/scale family with a finite second moment - like the logistic, for example. [the pdfs need not be symmetric, tho.] –  ronaf Oct 19 '10 at 3:34
altho, as whuber points out, there are two excel functions for variance, if my recollection is correct, there is only one for covariance - and it divides by n, not n-1. [i haven't checked the latest version of excel, tho. can someone tell us if that is still the case?] –  ronaf Oct 19 '10 at 3:56
show 1 more comment

Use VAR (with n-1 denominator) when you wish to estimate the variance of the underlying population from the sample, or VARP (with n denominator) when the sample is the population.

I find the name "population variance" quite ambiguous...

-