- Probability weight is greater than 979
round(1-pnorm(q=979 , mean = 1300 , sd=sqrt(40000), lower.tail=TRUE), digits=4)
## [1] 0.9458
- Probability that the life span of the monitor will be more than 8340 hours
round(1-pnorm(q=8340 , mean = 11000 , sd=sqrt(1960000), lower.tail=TRUE),digits=4)
## [1] 0.9713
- Probability that a randomly selected firm will earn between 83 and 85 million dollars?
p1 <- 1-pnorm(q=83000000, mean=80000000, sd=3000000, lower.tail=TRUE)
p2 <- 1-pnorm(q=85000000, mean=80000000, sd=3000000, lower.tail=TRUE)
round(p1-p2,digits=4)
## [1] 0.1109
- Minimum score required for the job offer?
round(qnorm(p=.14, mean=456, sd=123, lower.tail=FALSE),digits=0)
## [1] 589
- Find the two lengths that separate the top 7% and the bottom 7%.
round(qnorm(p=.07, mean=6.13, sd=.06), digits=2)
## [1] 6.04
round(qnorm(p=.07, mean=6.13, sd=.06, lower.tail=FALSE), digits=2)
## [1] 6.22
- Find the numerical limits for a C grade
round(qnorm(p=.2, mean=78.8, sd=9.8), digits=0)
## [1] 71
round(qnorm(p=.45, mean=78.8, sd=9.8, lower.tail=FALSE), digits=0)
## [1] 80
- minimum score required for admission?
round(qnorm(p=.45, mean=21.2, sd=5.4, lower.tail=FALSE), digits=1)
## [1] 21.9
- Probability <11/151 students will not graduate on time.
round(pbinom(q = 10, size = 151, prob = 0.09, lower.tail = TRUE),4)
## [1] 0.192
smple <- rnorm(n=147,mean=48,sd=7)
se <- sd(smple)/sqrt(147)
round(pnorm(q=48.83 , mean=48 , sd=se, lower.tail=FALSE),4)
## [1] 0.0856
smple <- rnorm(n=68,mean=91,sd=10)
se <- sd(smple)/sqrt(length(smple))
round(pnorm(q=93.54 , mean=91 , sd=se, lower.tail=FALSE),4)
## [1] 0.0229
fisher_z <- function(r) {.5 * log((1+r)/(1-r))}
fisher_se <- function(n) {1/sqrt(n-3)}
x4 <- fisher_z(.04)
x10 <- fisher_z(.1)
m <- fisher_z(.07)
se <- fisher_se(540)
round(pnorm(x10, m, se)-pnorm(x4, m, se),4)
## [1] 0.5153
x27 <- fisher_z(.27)
x19 <- fisher_z(.19)
m <- fisher_z(.23)
se <- fisher_se(602)
round(pnorm(x27, m, se, lower.tail=FALSE)+pnorm(x19, m, se),4)
## [1] 0.301
m <- 3.9
sd <- .8
N <- 208
ci <- .8
p <- ( 1 - ci ) / 2
t <- qt(p, N-1)
round(m + t * sd / sqrt(N),1)
## [1] 3.8
round(m - t * sd / sqrt(N),1)
## [1] 4
m <- 16.6
sd <- 11
N <- 7472
ci <- .98
p <- (1-ci)/2
t <- qt(p, N-1)
round(m + t * sd / sqrt(N),1)
## [1] 16.3
round(m - t * sd / sqrt(N),1)
## [1] 16.9
print("The top right image describes the problem")
## [1] "The top right image describes the problem"
round(abs(qt(.05, 26-1)),4)
## [1] 1.7081
sample <- c(383.6, 347.1, 371.9, 347.6, 325.8, 337)
n <- length(sample)
m <- round(mean(sample),2)
m
## [1] 352.17
sd <- round(sd(sample),2)
sd
## [1] 21.68
#crit value
t <- round(abs(qt(.10/2, n-1)),3)
t
## [1] 2.015
#90% interval:
se <- sd(sample)/sqrt(n)
lower <- round(m - t*se, 2)
upper <- round(m + t*se, 2)
lower
## [1] 334.34
upper
## [1] 370
n <- 16
m <- 46.4
sd <- 2.45
t <- round(abs(qt(.2/2, n-1)), 3)
t
## [1] 1.341
se <- sd/sqrt(n)
lower <- round(m-t*se,2)
upper <- round(m+t*se,2)
lower
## [1] 45.58
upper
## [1] 47.22
m <- 8
sd <- 1.9
se <- .13
z <- 2.576
n <- round((z*sd/se)^2,0)
n
## [1] 1417
m <- 12.6
sd <- sqrt(3.61)
se <- .19
z <- 1.96 #95% confidence level zscore
round((z * sd / se)^2,0)
## [1] 384
n <- 2089
phat <- 1-(1734/n)
#proportion reading <= 8th grade level
round(phat, 3)
## [1] 0.17
#98% confidence interval
se <- sqrt(phat*(1-phat)/n)
z <- abs(qt(.02/2, n-1))
lower <- phat - z * se
upper <- phat + z * se
round(lower,3)
## [1] 0.151
round(upper,3)
## [1] 0.189
n <- 474
phat <- 156/n
#proportion reading <= 8th grade level
round(phat, 3)
## [1] 0.329
#98% confidence interval
se <- sqrt(phat*(1-phat)/n)
z <- abs(qt(.05/2, n-1))
lower <- phat - z * se
upper <- phat + z * se
round(lower,3)
## [1] 0.287
round(upper,3)
## [1] 0.372