Two Proportion Z-Test \(H_0\): \(p_1\) = \(p_2\) \(H_a\): \(p_1\) > \(p_2\)
Where: \(p_1\) = proportion of females taking biology exam \(p_2\) = proportion of females taking calculus AB exam
α = 0.05
prop.test(c(84200, 144790), c(102598, 211693), alternative = "greater")
##
## 2-sample test for equality of proportions with continuity correction
##
## data: c(84200, 144790) out of c(102598, 211693)
## X-squared = 6531.4, df = 1, p-value < 2.2e-16
## alternative hypothesis: greater
## 95 percent confidence interval:
## 0.1341319 1.0000000
## sample estimates:
## prop 1 prop 2
## 0.8206788 0.6839622
**Result: p-value: 2.2e-16.
The p-value: 2.2e-16 < α = 0.05. This is strong evidence that the proportion of females students taking the biology exam is higher than the proportion of females students taking the calculus AB exam.
Two Sample T-Test \(H_0\): \(\mu_1\) = \(\mu_2\) \(H_a\): \(\mu_1\) < \(\mu_2\)
Where: \(\mu_1\): infants that cried less on average held by their mothers \(\mu_2\): infants that cried less on average held using conventional methods
α = 0.05
mothers <- c(0, 32, 20, 23, 14, 19, 60, 59, 64, 64, 72, 50, 44, 14, 10, 58, 19, 41, 17, 5, 36, 73, 19, 46, 9, 43, 73, 27, 25, 18)
conventional_methods <- c(63, 0, 2, 46, 33, 33, 29, 23, 11, 12, 48, 15, 33, 14, 51, 37, 24, 70, 73, 0, 73, 39, 54, 52, 39, 34, 30, 55, 58, 18)
t.test(mothers, conventional_methods, conf.level = 0.95, alternative = "less")
##
## Welch Two Sample t-test
##
## data: mothers and conventional_methods
## t = -0.088794, df = 57.878, p-value = 0.4648
## alternative hypothesis: true difference in means is less than 0
## 95 percent confidence interval:
## -Inf 8.912894
## sample estimates:
## mean of x mean of y
## 35.13333 35.63333
Result: p-value = 0.4648
The p-value = 0.4648 > α = 0.05. This is not enough evidence to show that infants cried less on average when they are held by their mothers than if held using conventional methods.