Question

sing R please, 1. Generate 5,000 iid samples from the standard normal distribution; compute the mean of these random samples.
please i need to solve 2 and 3 and please explain everything and write I commend

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Q2)from definition 922 LXNBCmie) 2 a 12 an pix=n) = m pa di-pm-x from m defenition mean = E(0) - E x p(x)= E a.m x=0 Ela) = px (

Q3) Please ignore Q2) written in the image this is your answer for question 3.292) P(X=2) = e-^ a) likelihood an L = echt aber I di t=1 log - likelihood log i = -ux & & ni log A-log Ti si b) de landele c

R code for part 3

llh=rep(0,40)

#different paramenters to see which one we maximise
lambdas=seq(1,20.5,by=0.5)
for(i in 1:40)
{ #here we are generating random sample of 1000 from poisson with parameter 6
y=rpois(1000,6)
#llh is log likelihood
llh[i]<- sum(dpois(y,lambdas[i], log=TRUE))
}
final=data.frame(lambdas,llh)
plot(final)

Run 2 Source = H E Import Dataset, = List Source on Save 1 lambda=2 2 llh=rep(0,40) (Global Environment - values 40L lambda l

So we can in the plot we get our maximum at lambda=6 from which we generated the poisson sample hence validating our experiment.

Hey I have put a lot effort for this please upvote If I am able to help you

Thanks

Add a comment
Know the answer?
Add Answer to:
please i need to solve 2 and 3 and please explain everything and write I commend...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Please solve on only PART 2 b) and c) , PART 1 is only for REFERENCE...

    Please solve on only PART 2 b) and c) , PART 1 is only for REFERENCE :) Part I: Ene concept of a percentile (equivalently, quantile) is very important in data analysis. It applies to both samples and distributions. So, let's get some wi practice with them, starting with the binomial distribution. In prelab, you learned that the function gbinom(p. size prob) gives the p-th quantile of the binomial distribution with parameters n - size and pi prob. tocus on...

  • Please answer the question clearly. Consider a random sample of size n from a Poisson population...

    Please answer the question clearly. Consider a random sample of size n from a Poisson population with parameter λ (a) Find the method of moments estimator for λ. (b) Find the maximum likelihood estimator for λ. Suppose X has a Poisson distribution and the prior distribution for its parameter A is a gamma distribution with parameters and β. (a) Show that the posterior distribution of A given X-x is a gamma distribution with parameters a +r and (b) Find the...

  • SOLVE the following in R code: iid Let X1, , Xn ~ U (0,0). We are...

    SOLVE the following in R code: iid Let X1, , Xn ~ U (0,0). We are going to compare two estimators for θ: 01-2X, the method of moments estimator -maxX.... X1, the maximum likelihood estimator I. Generate 50,000 samples of size n-50 from U(0,5). For each sample compute both θ1 and 02 (Hint: You can use the R cornmand max (v) to find the maximum entry of a vector v). The results should be collected in two vectors of length...

  • Need to use Rstudio for this question A government grants is funding a study to calculate...

    Need to use Rstudio for this question A government grants is funding a study to calculate how long it takes for the average consumer to establish an Internet connection. A random sample of 20 Internet users’ connection time is collected. The connections time in seconds are 0.03, 0.48, 0.49, 0.52, 0.66, 0.67, 0.70, 0.76,0.82, 1.2, 1.22, 1.39, 1.62, 1.85, 1.97, 2.25, 2.84, 3.11, 3.48, 4.02 Use chi-square test to see if it is reasonable to assume that internet connection time...

  • Please give detailed steps. Thank you. 5. Let {X, : i-1..n^ denote a random sample of...

    Please give detailed steps. Thank you. 5. Let {X, : i-1..n^ denote a random sample of size n from a population described by a random varaible X following a Poisson(θ) distribution with PDF given by θ and var(X) θ (i.e. you do not You may take it as given that E(X) need to show these) a. Recall that an estimator is efficient, if it satisfies 2 conditions: 2) it achieves the Cramer-Rao Lower Bound (CLRB) for unbiased estimators: Show that...

  • please explain step by step and write with clear handwriting. thank you maat is sampling dist....

    please explain step by step and write with clear handwriting. thank you maat is sampling dist. Of sample mean for large sample (>30) and pop not normal 25 Given a continuous random variable (X), NOT normally distributed, where the sample size (n), the mean (), and standard deviation (o) are shown on right, what is the sampling distribution of X-Bar you would use in this course. = 12 O= n = 55 I I a b Binomial t-Dist Poisson Normal...

  • 4 and 5 samples, the other in small samples. Which is which? Explain. (d) Suppose we...

    4 and 5 samples, the other in small samples. Which is which? Explain. (d) Suppose we know that the 5 values are from a symmetric distribution. Then the sample median is also unbiased and consistent for the population mean. The sample mean has lower variance. Would you prefer to use the sample 4. Suppose Yi, Y, are iid r ables with E(n)-μ, Var(K)-σ2 < oo. For large n, find the approximate 5. Suppose we observe Yi...Yn from a normal distribution...

  • . A random sample of size n is taken from a population that has a distri- bution with density fun...

    . A random sample of size n is taken from a population that has a distri- bution with density function given by 0, elsewhere Find the likelihood function L(n v.. V ) -Using the factorization criterion, find a sufficient statistic for θ. Give your functions g(u, 0) and h(i, v2.. . n) - Use the fact that the mean of a random variable with distribution function above is to find the method of moment's estimator for θ. Explain how you...

  • Conduct a computer simulation to generate the sample means of Poisson random variables. First generate X...

    Conduct a computer simulation to generate the sample means of Poisson random variables. First generate X ∼ Poisson(3), and plot a histogram of this Poisson random variable. Then generate X = 1/5(X1 + X2 + X3 + X4 + X5), where X1, X2, . . . , X5 are all from Poisson(3). Plot a histogram of this sample mean statistic X. Compare the histograms and describe the changes you see in the histograms. Explain the changes using Central Limit Theorem....

  • Suppose x has a distribution with a mean of 90 and a standard deviation of 3....

    Suppose x has a distribution with a mean of 90 and a standard deviation of 3. Random samples of size n = 36 are drawn. (a) Describe the x distribution and compute the mean and standard deviation of the distribution. x has  ---Select--- a normal a geometric an unknown a Poisson a binomial an approximately normal distribution with mean μx = and standard deviation σx =  . (b) Find the z value corresponding to x = 91. z = (c) Find P(x...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT