/*! This file is auto-generated */ .wp-block-button__link{color:#fff;background-color:#32373c;border-radius:9999px;box-shadow:none;text-decoration:none;padding:calc(.667em + 2px) calc(1.333em + 2px);font-size:1.125em}.wp-block-file__button{background:#32373c;color:#fff;text-decoration:none} Q4SE Let X and Y be independent rando... [FREE SOLUTION] | 91Ó°ÊÓ

91Ó°ÊÓ

Let X and Y be independent random variables with \(X\) having the t distribution with five degrees of freedom and Y having the t distribution with three degrees of freedom. We are interested in \(E\left( {|X - Y|} \right).\)

a. Simulate 1000 pairs of \(\left( {{X_i},{Y_i}} \right)\) each with the above joint distribution and estimate \(E\left( {|X - Y|} \right).\)

b. Use your 1000 simulated pairs to estimate the variance of \(|X - Y|\) also.

c. Based on your estimated variance, how many simulations would you need to be 99 percent confident that your estimator is within the actual mean?

Short Answer

Expert verified

(a) Close to\(1.3755\)for\(n = 10000.\)

(b) Close to\(1.3656\)for\(n = 10000.\)

((c)) n=10071.

Step by step solution

01

(a) To find the estimated expected value varies around.

The code below gives an estimate of the\(E\left( {|X - Y|} \right).\)To obtain the estimate, and one should generate random numbers from the joint distribution\(\left( {X, Y} \right).\)As the random variables are independent, one may generate random numbers from the distribution of X and distribution of Y.

For the simulation, the sample size of \(n = 10000\) is used. The estimate of the expected value varies around \(1.3755.\)

02

(b) To find the estimated variance around

The same code gives the estimate of the variance of\(\left( {X, Y} \right).\)using the sample variance of generated sample for\(\left( {X, Y} \right).\)The estimate is around 1.3656.

03

(c) To find the simulation and mean.

Lastly, the necessary simulation sample size may be found from

As \(\sigma \) is unknown in this case, use the estimate obtained in (b), which is \(\sqrt {1.3656} .\) Here, \(\gamma = 0.99\) and . Remember that \(\Phi \) is the cdf of the standard normal distribution. Then, the necessary sample size which satisfies the requirements is

\(\begin{aligned}{c}n = {\Phi ^{ - 1}}\frac{{1 + \gamma }}{2}\frac{{{s^2}}}{ \in }\\ = {\Phi ^{ - 1}}\frac{{1 + 0.99}}{2}\;\;\;{\kern 1pt} \frac{{{{\sqrt {1.367} }^2}}}{{0.01}}\\ = 10071\end{aligned}\)

However, the simulation sample size will differ every time you run the code (unless you place "seed" before).

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with 91Ó°ÊÓ!

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Assume that one can simulate as many \({\bf{i}}.{\bf{i}}.{\bf{d}}.\)exponential random variables with parameters\({\bf{1}}\) as one wishes. Explain how one could use simulation to approximate the mean of the exponential distribution with parameters\({\bf{1}}\).

In Example 12.5.6, we used a hierarchical model. In that model, the parameters\({\mu _i},...,{\mu _P}\,\)were independent random variables with\({\mu _i}\)having the normal distribution with mean ψ and precision\({\lambda _0}{T_i}\,\)conditional on ψ and\({T_1},\,....{T_P}\). To make the model more general, we could also replace\({\lambda _0}\)with an unknown parameter\(\lambda \). That is, let the\({\mu _i}\)’s be independent with\({\mu _i}\)having the normal distribution with mean ψ and precision\(\,\lambda {T_i}\)conditional on\(\psi \),\(\lambda \) and\({T_1},\,....{T_P}\). Let\(\lambda \)have the gamma distribution with parameters\({\gamma _0}\)and\(\,{\delta _0}\), and let\(\lambda \)be independent of ψ and\({T_1},\,....{T_P}\). The remaining parameters have the prior distributions stated in Example 12.5.6.

a. Write the product of the likelihood and the prior as a function of the parameters\({\mu _i},...,{\mu _P}\,\), \({T_1},\,....{T_P}\)ψ, and\(\lambda \).

b. Find the conditional distributions of each parameter given all of the others. Hint: For all the parameters besides\(\lambda \), the distributions should be almost identical to those given in Example 12.5.6. It wherever\({\lambda _0}\)appears, of course, something will have to change.

c. Use a prior distribution in which α0 = 1, β0 = 0.1, u0 = 0.001, γ0 = δ0 = 1, and \({\psi _0}\)= 170. Fit the model to the hot dog calorie data from Example 11.6.2. Compute the posterior means of the four μi’s and 1/τi’s.

Let \({{\bf{X}}_{\bf{1}}},...,{{\bf{X}}_n}\) be i.i.d. with the normal distribution having mean \(\mu \) and precision \(\tau \).Gibbs sampling allows one to use a prior distribution for \(\left( {\mu ,\tau } \right)\) in which \(\mu \) and\(\tau \) are independent. With mean \({\mu _0}\) and variance, \({\gamma _0}\) Let the prior distribution of \(\tau \)being the gamma distribution with parameters \({\alpha _0}\) and \({\beta _0}\) .

a. Show that the Table \({\bf{12}}{\bf{.8}}\) specifies the appropriate conditional distribution for each parameter given the other.

b. Use the new Mexico nursing home data(Examples \({\bf{12}}{\bf{.5}}{\bf{.2}}\,{\bf{and}}\,{\bf{12}}{\bf{.5}}{\bf{.3}}\) ). Let the prior hyperparameters be \({{\bf{\alpha }}_{\bf{0}}}{\bf{ = 2,}}{{\bf{\beta }}_{\bf{0}}}{\bf{ = 6300,}}{{\bf{\mu }}_{\bf{0}}}{\bf{ = 200}}\), and \({\gamma _0} = 6.35 \times {10^{ - 4}}.\) Implement a Gibbs sampler to find the posterior distribution \(\left( {\mu ,\tau } \right).\,\) . In particular, calculate an interval containing \(95\) percent of the posterior distribution of \(\mu \)

Use the data in Exercise 16 of Sec. 10.7.

a. Use the nonparametric bootstrap to estimate the variance of the sample median.

b. How many bootstrap samples does it appear that you need to estimate the variance to within .005 with a probability of 0.95?

Suppose that \({x_1},...,{x_n}\) from a random sample from an exponential distribution with parameter\(\theta \).Explain how to use the parametric bootstrap to estimate the variance of the sample average\(\overline X \).(No simulation is required.)

See all solutions

Recommended explanations on Math Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.