Random Variables
A random variable is a number-valued function of the outcome — the language of expectation.
The idea
A random variable is a rule $X$ that assigns a number $X(\omega)$ to each outcome $\omega$ in the sample space. Flip a coin and set $X = 1$ for heads and $X = 0$ for tails; roll two dice and let $X$ be the sum of the faces, or the larger of them.
We attach numbers because outcomes themselves need not be numbers — a coin lands heads or tails — while nearly everything we want to do with chance, such as averaging, adding, or measuring spread, works on numbers.
$X$ is not a probability: it is a value, free to equal $7$ or $-2$. And the randomness lies in which outcome occurs, not in the rule $X$, which simply reports a number once an outcome has occurred.
For a discrete random variable, whose possible values form a finite or countable list, the outcomes that $X$ sends to any one value $x$ form an event, so it has a probability $\mathbb{P}(X = x)$. The list of these probabilities specifies the distribution of $X$, and its entries total $1$. For a continuous random variable, we instead describe probabilities of intervals; a single exact value can have probability $0$.
Ways to work on it
- Walkthrough. Definition, distribution, and probabilities — coins and dice.
- Practice. Find probabilities for the sum of two dice by counting outcomes.
- Hardest. Work out the distribution of the minimum, maximum, or difference of two dice.
Not sure where to start? Take the ten-question placement test.