Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use R to answer the following questions. Make sure that all plots have meaningful titles and axis labels. Also, as usual, make sure to include

image text in transcribed
image text in transcribed
Use R to answer the following questions. Make sure that all plots have meaningful titles and axis labels. Also, as usual, make sure to include well-commented code, either with each problem or as an appendix. 1. [20 pts total] (a) [4 pts] Let n = 20. Simulate n observations from a Uniform[0, 1] distribution. Plot a histogram of the sample. (b) [8 pts] Now we will simulate the sampling distribution of the sample mean of a sample of size nfrom a Uniform[01 1] distribution. To do this: =k Let B : 1000 be the number of simulations. at: Create a vectcar, say samplemeanvec, of length B to store the sample means. 4: Then, B times, generate a sample of size n from a Uniform[0, 1] distribution and store the mean in samplemeanvec Plot a histogram of these sample means. (0) [8 pts] Repeat parts (a) and (b) for n = 5 and n = 100. Comment on the shape of the histograms. How do the histograms of the samples change as it changes? How do the histograms of the sample means change as 11 changes? 2. [20 pts total] Repeat problem 1, but sampling from the geometric distribution with p = 0.1. (Note: Feel free to just use the parametrization in R i.e., letting the random variable here count the number of failures before the rst success rather than the number of trials until the rst success including that success.) 3. [20 pts total] Repeat problem 1, but sampling from the normal distribution with mean 0 and variance 1

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Entrepreneurship

Authors: Andrew Zacharakis, William D Bygrave

5th Edition

1119563097, 9781119563099

Students also viewed these Mathematics questions