Discrete random variance
The variance is, in short, a measure of how much the values of a random variable differ from the mean. It’s the square of the standard deviation.
Notation
We write the variance of a list of values
Formula
Suppose we have a list of possible discrete values and their probabilities.
The value at position
The variance of the list is calculated by:
Var(X) = E(X^2) - (E(X))^2
We can substitute the formula for expectation into this -
Var(X) = \sum x_n^2 p_n - \left( \sum x_n p_n \right)^2