Question: Assume random variable X has Binomial probability distribution function with n = 49 and probability of success p. For different values of p, from 0.1
Assume random variable X has Binomial probability distribution function with n = 49 and probability of success p. For different values of p, from 0.1 to 0.9 with increments of 0.1 (0.1, 0.2, ..., 0.9) perform the following tasks. 1. Take a random sample of 5000 from binomial distribution with n = 49 and given p. Estimate the probability of success and save it in a vector. 2. Approximate the sampling distribution of p_hat using histogram and fit a distribution curve using density function (two panels in the same figure with 2 by 2 panels). 3. Calculate absolute estimation error and visualize it using histogram (panel three of the same figure). 4. Use qqnorm to test the Normality of sampling distribution of p_hat (panel 4 of the same figure). 5. Calculate average p_hat and (p p_hat) and save them. 6. Repeat from 1 for all values of p.
IN R
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
