Write a program in (mathrm{R}) that generates a sample (X_{1}, ldots, X_{n}) from a specified distribution (F)

Question:

Write a program in \(\mathrm{R}\) that generates a sample \(X_{1}, \ldots, X_{n}\) from a specified distribution \(F\) and computes the sample mean \(\bar{X}_{n}\). Use this program with \(n=5,10,25,50,100\), and 1000 and plot the sample size against \(\bar{X}_{n}\). Repeat the experiment five times, and plot all the results on a single set of axes. Produce the plot described above for each of the following distributions \(\mathrm{N}(0,1), \mathrm{T}(1)\), and \(\mathrm{T}(2)\). For each distribution state whether the Strong Law of Large Numbers or the Weak Law of Large Numbers regulates the behavior of \(\bar{X}_{n}\). What differences in behavior are observed on the plots?

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: