HW5 - 6 a x=c(rep(0,96,rep(1,4 xx=sample(x,100000,rep=T...

Info icon This preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
6 a. x=c(rep(0,96),rep(1,4)) xx=sample(x,100000,rep=T) newx=matrix(xx,1000,100) y=rowSums(newx) hist(y) Histogram of y y Frequency 0 2 4 6 8 10 0 50 100 150 200 This histogram is unimodal skewed to the right with the right tail being longer than the left. b. > summary(as.factor(y) 0 1 2 3 4 5 6 7 8 9 10 11 16 62 154 191 215 152 106 50 33 13 4 4 /1000 .016 .062 .154 .191 .215 .152 .106 .050 . 033 .013 .004 .004 Lamda = 4
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Pr 0 0.0183 1 0.0733 .016 2 0.1465 .154 3 0.1954 .191 4 0.1954 .215 5 0.1563 .152 6 0.1042 .106 7 0.0595 .050 8 0.0298 .033 9 0.0132 .013 10 0.0053 .004 11 0.0019 .004 12 0.0006 13 0.0002 14 0.0001 These are pretty close the relative frequencies in the binomial model, the poisson probabilities are more spread out than the ones from the histogram, but despite this difference the probabilities are the same and get closer to the same number around the median of the binomial model. c. > sd(y) [1] 1.960522 Sqrt(100*.04*.96) Sd=sqrt(npq) = 1.9595 Sd poisson = sqrt(lamda) = 2.
Image of page 2
7. a. x=c(rep(0,60),rep(1,40)) xx=sample(x,100000,rep=T) newx=matrix(xx,1000,100) y=rowSums(newx) hist(y) Histogram of y y Frequency 20 30 40 50 60 0 100 200 300 400 The histogram is still unimodal and is symmetric and is more centered around 40.
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern