Random Variables
| English | Chinese | Pinyin |
|---|---|---|
| random variable | 随机变量 | suí jī biàn liàng |
| probability distribution | 概率分布 | gài lǜ fēn bù |
| discrete random variable | 离散随机变量 | lí sàn suí jī biàn liàng |
| continuous random variable | 连续随机变量 | lián xù suí jī biàn liàng |
A number that depends on chance
- A random variable 随机变量 assigns a number to each outcome of a chance process.
- Example: $X =$ the number of heads in $3$ coin flips.
- Its value is decided by randomness, so it has a probability distribution.
- Random variables let us do arithmetic with chance.
Discrete vs. continuous
- A discrete random variable 离散随机变量 takes countable, separate values ($0, 1, 2, \dots$).
- A continuous random variable 连续随机变量 can take any value in an interval (heights, times).
- Count → discrete; measure on a scale → continuous.
- This unit focuses on discrete distributions (a table of values and probabilities).
The probability distribution
- A probability distribution 概率分布 lists each value $x$ with its probability $P(x)$.
- Two rules make it valid: each $0 \le P(x) \le 1$, and all the $P(x)$ sum to $1$.
- It can be shown as a table or a bar-style graph.
- The distribution is the complete description of the random variable.
Probabilities of events
- To find $P(X \ge 2)$ or $P(X = 1)$, just add the relevant $P(x)$ values.
- "$X$ at least $2$" = $P(2) + P(3) + \cdots$.
- "$X$ between" = sum the probabilities in that range.
- Every event probability is a sum of the listed pieces.
A probability distribution must have all $P(x)$ in $[0,1]$ summing to exactly $1$ — if a table's probabilities don't total $1$, it isn't valid. And keep discrete vs. continuous straight: you count a discrete variable (number of heads) but measure a continuous one (a person's exact height) — the tools differ.
$X =$ heads in $2$ fair flips. Distribution: $P(0)=0.25,\ P(1)=0.5,\ P(2)=0.25$.
- Valid? All in $[0,1]$ and $0.25+0.5+0.25 = 1$. ✓
- $P(X \ge 1) = P(1) + P(2) = 0.5 + 0.25 = 0.75$.
- $P(X = 2) = 0.25$ — exactly two heads.
A random variable assigns a number to each outcome. A discrete one takes countable values; a continuous one takes any value in an interval. Its probability distribution lists $P(x)$ with each in $[0,1]$ summing to $1$; event probabilities like $P(X\ge 2)$ are sums of the relevant $P(x)$.
A discrete probability distribution
Each bar is P(x); the bars sum to 1.
The number of heads in 3 coin flips is which kind of random variable?
It takes countable separate values (0,1,2,3) — discrete.
In a valid probability distribution, the probabilities must sum to 1.
All P(x) in [0,1] and summing to exactly 1.
X = heads in 2 flips: P(0)=0.25, P(1)=0.5, P(2)=0.25. Find P(X ≥ 1).
P(1)+P(2) = 0.5 + 0.25 = 0.75.
A person's exact height is which kind of variable?
Height is measured on a scale — continuous.
A rule assigning a number to each outcome of a chance process is a ___ variable.
That's the definition of a random variable.