From: "Robert I. Eachus" <rieachus@comcast.net>
Subject: Re: Incremental statistics functions
Date: Tue, 27 Jan 2004 11:22:40 -0500
Date: 2004-01-27T11:22:40-05:00 [thread overview]
Message-ID: <JM6dnTWuFuXMDYvdRVn-uw@comcast.com> (raw)
In-Reply-To: <44lRb.124968$sv6.677741@attbi_s52>
Steve wrote:
> An incremental algorithm for standard deviation is easy. An incremental
> algorithm for variance (as far as I know) is not possibile. It is my
> understanding that standard deviation is really an approximation of variance
> that is easier to calculate.
No the variance is the square of the standard deviation, and the
standard deviation is the (positive) square root of the variance.
However, note that there are two ways to calculate the variance/standard
deviation and only one is right. If you are calculating the variance of
a complete set of values, or using an externally defined mean, you
divide by the number of values. But if you are using a sample, and
estimating the mean from the sample you divide by n-1. (This says you
can't estimate the variance from one sample, which is as it should be.)
--
Robert I. Eachus
"The war on terror is a different kind of war, waged capture by capture,
cell by cell, and victory by victory. Our security is assured by our
perseverance and by our sure belief in the success of liberty." --
George W. Bush
next prev parent reply other threads:[~2004-01-27 16:22 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-26 22:59 OT: Incremental statistics functions Mats Karlssohn
2004-01-27 1:50 ` tmoran
2004-01-27 2:13 ` Stephen Leake
2004-01-27 3:37 ` Robert I. Eachus
2004-01-27 4:56 ` tmoran
2004-01-28 0:22 ` tmoran
2004-01-28 19:56 ` OT: large sums; was " tmoran
2004-01-27 3:39 ` Steve
2004-01-27 16:22 ` Robert I. Eachus [this message]
2004-01-27 15:48 ` Joachim Schr�er
2004-01-28 0:22 ` tmoran
2004-01-27 23:44 ` OT: " Mats Karlssohn
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox