Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can you help me to figure out that using Monte Carlo simulation in R studio to prove that for a sample of n random observations

can you help me to figure out that using Monte Carlo simulation in R studio to prove that for a sample of n random observations drawn from a normal distribution (mean is 0 and standard deviation is 2), the sample variance calculated by dividing the sum of squared deviations (each observation minus the sample mean, then squared) with n-1 is an unbiased estimator of the population standard deviation, but the sample variance calculated by dividing the sum with n is a biased estimator.

hint: Repeatedly draw n observations for a large number of times, say 10,000 times. For each draw, calculate the two versions of the sample variance. When you are done with the 10,000 rounds, plot the histograms of the two versions of the sample variance across the 10,000 rounds, and investigate which version of the sample variance has a mean that is almost the same with the true standard deviation and which one has a mean that is more different. Use comments to describe your findings.

as well as the variance of the mean of n observations independently drawn from the same distribution equals the variance of each observation divided by n).

Hint: Repeatedly draw n observations (say, let n =10 first) from a normal distribution (0 mean and 1 standard deviation) for 10,000 times. For each draw, calculate the mean. Across the 10,000 times, you have 10,000 means. Calculate the variance of the 10,000 means and see if it approximately equals 1/n of the variance, which is 1 in this case (Note that variance is the squared standard deviation, so if the standard deviation is 1, the variance is also 1). Then run a loop of the above loop by letting n=10, 15, 20, 25, 30, 35, and 40 (consider codes such as "for(i in c(10,15,20,25,30,35,40))") and record the variance for each n. Plot the variance for each n against the value of n using "plot". Use comments to describe your finding.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored 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

More Books

Students also viewed these Databases questions