Topic 1 · Lesson 1 of 3
Expectation and variance
Probability distributions
A probability distribution lists every value that can take with its probability . It may be given as a table or as a probability function, a formula such as for . Either way, two facts always hold:
- every probability is between 0 and 1;
- the probabilities add up to 1: .
The second fact is how you find an unknown constant. For , : , so .
The cumulative distribution function is . To get back to the probabilities, subtract consecutive values: .
Expected value
The expected value (or mean) of is
Multiply each value by its probability and add. For example, if takes the values 1, 2, 3, 4 with probabilities 0.2, 0.3, 0.4, 0.1, then
need not be a value can take: no single experiment gives 2.4, but the average of many results will be close to it.
If the distribution is symmetrical, the mean is at the centre of symmetry. A table with and has without any calculation.
Expected value of a function of X
For any function ,
Apply the function to each value, keep the same probabilities, and add. With the distribution above,
In general (here ), and . Never "apply the function to the mean".
Variance
The variance measures spread about the mean:
The second form is the one to use: "the mean of the squares minus the square of the mean". Above, , and the standard deviation is .
A variance can never be negative. If you get a negative answer, you have probably subtracted the wrong way round or used instead of .
The formula also works backwards: . If and , then .
Worked example
A probability function
The random variable has for . Find , and .
Show solutionHide solution
- Probabilities add to 1: , so .
- The distribution is for .
- .
- , so .
Worked example
Unknown probabilities
The random variable takes the values 1, 2, 3, 4 with probabilities , , , , and . Find and .
Show solutionHide solution
Two unknowns need two equations.
- Sum of probabilities: , so .
- Mean: , so .
Subtracting, : and . With three unknowns you need a third equation, usually from a given variance, through .
Practise this topic
Both are part of Premium.