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

Info iconThis 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
Background image of page 1

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

View Full DocumentRight 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.
Background 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
Background image of page 3

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

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

This homework help was uploaded on 10/07/2007 for the course ORF 245 taught by Professor Richardd.deveaux during the Spring '07 term at Princeton.

Page1 / 13

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

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online