Final project: Random variables
Investigating other random variables
- As part of your project on random variables you wrote a program to estimate the probability mass/density function for a particular random variable that worked by generating a large number of identically distributed random variables. Now write a program to estimate the cumulative probability distribution function for the same kind of random variable you wrote your project on.
- Suppose that $X$ is a geometric random variable with $p=0.5$. Now suppose that we generate a random variable $Z$ that is a function of $X$ using $Z = 2^X$. Write a python notebook that generates multiple instances of this random variable $\{ Z_i \}$. Draw a graph that shows how the sample mean, $\mu_n = \frac{1}{N} \sum_{i=1}^n Z_i$, changes as the number of variables it is calculated from increases. Discuss the behaviour of this sample mean and compare it to the behaviour that you observed for the other random variables you have investigated. Derive an expression for the expression for the expectation of this random variable and use this expression to explain why the sample mean for this random variable behaves in the way you observe.
- Write a program that generates random variables from a Cauchy distribution. Generate a large number of identically distributed Cauchy random variables and use this data to estimate the probability density function for your random variable.
- Discuss how Student's-t-distribution arises from sampling and how this distribution differs from the standard normal distribution. You should write a program that generates random variable from Student's-t-distribution and make sure that you plot the a graph of showing how the shape of the $t$ distribution changes as the number of degrees of freedom is increased.