Random Variable: Process generating random outcomes.
Sample: Outcomes from a random variable.
Descriptive Statistics: Summary of a sample.
Inferential Statistics: Educated guess about the random variable that generated a sample.
Matthew J. Crossley
2025
Random Variable: Process generating random outcomes.
Sample: Outcomes from a random variable.
Descriptive Statistics: Summary of a sample.
Inferential Statistics: Educated guess about the random variable that generated a sample.
Process that generates random outcomes.
Tied to a population.
Has possible outcomes defined by a sample space.
Is fundamentally defined by a probability distribution.
A population is the entire set of things under study.
E.g., all people in the world, all possible people in the world, all the neurons in the universe, the set of all possible action potential times relative to stimulus onset etc.
The set of all possible outcomes of a random variable.
E.g., the set of all possible rolls of a die is {1,2,3,4,5,6}. It is discrete and finite.
E.g., the set of all possible action potential times relative to stimulus onset spans the interval (0,∞). It is continuous and infinite.
Describes the likelihood of each outcome in the sample space.
Discrete: A function that gives the probability of each outcome.
Continuous: A function that gives the probability density for each outcome.
The sample space goes on the x-axis.
The probability of each outcome goes on the y-axis.
Example: For a biased coin, the PMF is
P(X=x)={0.3if x=heads0.7if x=tails
Toss 1 | Toss 2 | Toss 3 |
---|---|---|
H | H | H |
H | H | T |
H | T | H |
H | T | T |
T | H | H |
T | H | T |
T | T | H |
T | T | T |
Example: Distribution of heights in Australia
Sample space: (0,∞)
Example: For a normal distribution with mean μ=0 and standard deviation σ=1, the PDF is
f(x)=1√2πe−x22
Discrete case: The probability of a particular outcome x is P(X=x).
Read this from a probability table or plot.
Continuous case: The probability of a range of values is the area under the curve.
Example: The probability of reaction time between 400-600 ms.
Consider a biased coin with PMF P(X=x)=0.3 for heads and P(X=x)=0.7 for tails.
Samples obtained from this distrubtion are random sequences of heads and tails.
Because the coin is biased, we expect to see more tails than heads.
A six-sided die is rolled, and the outcome is recorded. Which of the followin best describes the probability distribution of this random variable?
A. A probability density function (PDF) because the outcome is continuous.
B. A probability mass function (PMF) because the outcome is discrete.
C. A cumulative distribution function (CDF) because the outcome is deterministic.
D. A uniform density function because the outcome is continuous.
Correct Answer: B. A probability mass function (PMF) because the outcome is discrete.
A researcher is studying the distribution of human reaction times in milliseconds (ms) to a visual stimulus. The reaction time is measured as a continuous variable. Which of the following best describes the probability distribution used to model this data?
A. A probability mass function (PMF) because reaction time is discrete.
B. A probability density function (PDF) because reaction time is continuous.
C. A cumulative distribution function (CDF) because reaction time is always increasing.
D. A binomial distribution because reaction time is categorical.
Correct Answer: B. A probability density function (PDF) because reaction time is continuous.
You are rolling a fair six-sided die and want to compute the probability of rolling a number greater than 4.
Which of the following correctly calculates this probability?
A. P(X>4)=16+16=26=13
B. P(X>4)=1−P(X≤4)=1−46=13
C. P(X>4)=P(X=5)×P(X=6)=16×16=136
D. P(X>4)=P(X=4)+P(X=5)+P(X=6)=36=12
Correct Answer: A and B
The valid outcomes for X>4 are rolling a 5 or a 6.
Since the die is fair, P(X=5)=16 and P(X=6)=16.
Therefore,
P(X>4)=P(X=5)+P(X=6)=16+16=26=13
Alternatively, using the complement rule:
P(X>4)=1−P(X≤4)=1−46=13
A probability density function (PDF) is defined as follows:
f(x)=0.1 for 0≤x≤3
f(x)=0.2 for 3<x≤5
f(x)=0 otherwise
See next slide for the PDF plot.
What is the probability that a randomly drawn value from this distribution falls between x=2 and x=5?
A. 0.1×(3−2)+0.2×(5−3)=0.1+0.4=0.5
B. 0.1×(5−2)=0.3
C. 0.2×(5−2)=0.6
D. 0.1×(3−2)+0.2×(5−3)+0.1×(5−4)=0.1+0.4+0.1=0.6
Correct Answer: A
The probability is the area under the PDF curve from x=2 to x=5. Since the PDF consists of two rectangular sections, we compute the total area using basic geometry:
From x=2 to x=3, the height is 0.1, and the width is (3−2)=1:
Area=0.1×1=0.1
From x=3 to x=5, the height is 0.2, and the width is (5−3)=2:
Area=0.2×2=0.4
Total probability:
P(2≤X≤5)=0.1+0.4=0.5