- Hypothesis testing is a statistical procedure that is used to accept or reject a statistical hypothesis based on sample data
- It helps someone make decisions under uncertainty
2026-11-01
In hypothesis testing, we test two competing hypotheses:
Null hypothesis (\(H_0\)): this is a statement of no effect or no difference (results were due to random chance because there’s no actual relationship)
\[H_0: \mu = \mu_0\]
Alternative hypothesis (\(H_a\)): represents what we want to test for; there is an actual effect or difference
\[H_a: \mu \neq \mu_0 \quad \text{or} \quad \mu > \mu_0 \quad \text{or} \quad \mu < \mu_0\]
## ## 1-sample proportions test with continuity correction ## ## data: 55 out of 100, null probability 0.5 ## X-squared = 0.81, df = 1, p-value = 0.1841 ## alternative hypothesis: true p is greater than 0.5 ## 95 percent confidence interval: ## 0.462983 1.000000 ## sample estimates: ## p ## 0.55
## [1] "P-value: 0.18406012534676"
| \(H_0\) is True | \(H_0\) is False | |
|---|---|---|
| Reject \(H_0\) | Type I Error (\(\alpha\)) | Correct Decision (\(1 - \beta\)) |
| Fail to Reject \(H_0\) | Correct Decision (\(1 - \alpha\)) | Type II Error (\(\beta\)) |