4.1 - Random Variables
Questions Related To Inferential Statistics
Population -
Interest - proportion of vowels in population
Sampling method - SRS with
Important Questions
- What are the possible sample proportions?
- For each of the possible sample proportions, what is the probability of them occuring?
- If I repeatedly took SRS of size 3 from the popualtion, what would the typical sample proportion be?
- How varied will these sample proportions be?
The first two questions are basic questions to inferential statistics, but the last two, are what we're going to develop in the next chapters
Random Variable
Definition
Consider a random experiment and its sample space
Determine a method for assigning a numerical value to each outcome in the sample space
Identify the possible values:
- If the possible values contain a interval of real numbers, classify the random variable as continuous
- If the possible values do nto contain an interval of real numbers, classify the random variable as discrete
Determine probabilities based on classification and available knowledge - Discrete Random Variables have probability distributions. Each value will have a specific probability
- Continuous Random Variables have probability density functions. Each value will have a density, but probability is based on area under the density.
Based on that, the table in the Important Questions has the random variable marked as
Discrete Random Variables
Exercise 1
Rolling two fair, six-sided dice and construct the porbability distributions of the random variables using the following numerical assignment methods.
Sum of the two dice
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 |
Max of the Two Dice
| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 |
Excercise 2
Population -
Interest - proportion of vowels in population
Sampling method - i.i.d. random sampling with
Probability Distribution
Probability that sample is over-representative -
Probability that sample is unbiased -
Uniform Distributions
- A discrete random variable is uniformly distributed if every possible value is equally likely
- A continuous random variable is uniformly distributed if every possible value has the same probability
Uniform Discrete Random Variables
Example experiment - throwing a fair dice
Determine the probability of each possible value for a uniform, discrete random variable with
Expected Value
The expected value of a discrete random variable is the balancing point of the probability distribution (mean)
Expected value and mean are used interchangeably when discussing random variables
Caution: interpretation is important
- if a data set has been collected and analyzed - mean describes what happened
- random variables are predictive, provides info regarding the likelihood of what will happen
- the expected valie of a random variable is the long-term average - describes what will happen when we repeatedly run the experiment and analyze thet results by computing the mean
Example
Construct a uniform, discrete random variable with 4 possible values such that the expected value is equal to 5
Construct a discrete random variable that is not uniformly distributed with 5 possible values such that the expected value is equal to 5
| 20 | 0.05 | 1 |
| 16 | 0.25 | 4 |
| 8.57 | 0.35 | 3 |
| -6.7 | 0.15 | -1 |
| -10 | 0.2 | -2 |
| SUM | 1 | 5 |
Variance and Standard Deviation
Recall that the variance of a population data set was the average of the square deviations from the mean
The variance of a discrete random variable is defined as the expected value of the square deviations from the mean $$Var(X) = \sigma^2 = \sum(x-\mu)^2 \cdot P(X=x)$$
The standard deviation, as always, is the square root of the variance $$\sigma = \sqrt{ \sigma^2 }$$
Interpretation again is key
The variance of a random variable is the long-term variance - it describes what will happen if we repeatedly run the experiment and analyze the results by computing the variance
| 3 | |||
| 4 | |||
| 5 | |||
| 6 | |||
| 7 | |||