Exercise 7.1

Consider a random variable X with X ~ Bin(20, 0.4).

X ~ Bin (20, 0.4)

n1 <- 20
p1 <- 0.4

pbinom (13, n1, p1)
## [1] 0.9935341
miu1 <- n1*p1
sigma1 <- sqrt (n1*p1*(1-p1))

pnorm (13+0.5, miu1, sigma1)
## [1] 0.9939702

X ~ Bin (50, 0.8)

n2 <- 50
p2 <- 0.8

pbinom (41 - 1, n2, p2, lower.tail = FALSE)
## [1] 0.4437404
miu2 <- n2*p2
sigma2 <- sqrt (n2*p2*(1-p2))

pnorm (41 - 1 - 0.5, miu2, sigma2)
## [1] 0.4298419

Visualize these two scenarios

  • The approximation is closer for the first case (B (20, 0.4)), than the other.