Write a program in (mathrm{R}) that simulates two sequences of random variables. The first sequence is given

Question:

Write a program in \(\mathrm{R}\) that simulates two sequences of random variables. The first sequence is given by \(X_{1}, \ldots, X_{100}\) where \(X_{n}\) has a \(\operatorname{Uniform}(0, n)\) distribution for \(n=1, \ldots, 100\). The second sequence is given by \(Y_{1}, \ldots, Y_{100}\) where \(Y_{n}\) has a \(\operatorname{Uniform}\left(0, n^{2}ight)\) distribution for \(n=1, \ldots, 100\). Given the two sequences, compute the sequence \(X_{1} Y_{1}^{-1}, \ldots, X_{100} Y_{100}^{-1}\). Repeat the experiment five times and plot the resulting sequences of ratios. Describe the plots and address whether the behavior in the plots appears to indicate that the theory given in Exercise 6 has been observed.

Step by Step Answer:

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