Standard deviation of a random variable
By Jude Wallis · Updated
The standard deviation of a random variable, sigma-X, is the typical distance of its values from the mean mu-X over the long run.
The standard deviation of a random variable is the square root of its variance, and the variance is a probability-weighted average of squared distances from the mean: (sigma-X, with the mean of ). Each squared deviation is multiplied by the probability of that value, so an outcome that almost never happens contributes almost nothing however far out it sits. The answer is in the same units as , while the variance is in squared units.
Take the number of defective items in a box: 0 with probability 0.5, 1 with probability 0.3, and 2 with probability 0.2, giving mean . The weighted squared deviations are , and . They sum to the variance 0.610, and defects.
"Just take the standard deviation of 0, 1 and 2" is the wrong move, and it is a common one. Treating the three values as a list of data makes them equally likely, which they are not: as a population that returns 0.816, and with the divisor it returns 1.000. Neither one is . Notice also that no appears anywhere in the formula. There is nothing to divide by and no sample-size correction to make, because nothing was sampled. The probabilities have already done the weighting.
The value of is never negative, and it equals 0 in exactly one situation: when takes a single value with probability 1, so there is nothing to vary. It is a parameter of a distribution, not an estimate from data. When the random variable in question is itself a statistic, this same quantity is the standard deviation of its sampling distribution, and putting sample estimates in place of the parameters inside it is what turns it into a standard error.
This is topic 2.9 of Unit 2, Parameters of Random Variables.
More random variables and distributions terms, or browse the full statistics glossary.