A statistical hypothesis test is a method of statistical inference used to decide whether the sample data sufficiently supports a particular hypothesis about a population parameter. We typically consider two competing hypotheses:
- The null hypothesis (
): This is the default assumption or the status quo. It claims that the effect being studied does not exist - The alternative hypothesis (
or ): This is the hypothesis we’re testing against the null hypothesis.
The process involves collecting sample data and using it to determine whether there is enough evidence to reject the null hypothesis
The usage of hypothesis testing and p-value in particular is ubiquitous in scientific research. However, it is also controversial and are under heavy debate within the statistical and metascience community.
Subtopics
- null hypothesis and alternative hypothesis
- test statistic
- one-tailed and two-tailed tests
- p-value
- type I and type II errors
- confidence interval
- power
- degree of freedom
- hypothesis testing in R
Test Methods
Quantitative Variables
- Z-test - approximate quantitative variables with normal distribution
- Student’s T-test - approximate quantitative variables with t-distribution
Qualitative Variables
- Binomial test and Z-test for proportion - tests success probability in binary outcome experiments
- Chi-squared test - tests goodness-to-fit or independence for categorical data
Assumptions Tests
- Shapiro-Wilk Test - check the normality assumption
- Levene’s T test - tests equality of variances between two populations
Steps
When perform hypothesis testing, we typically have the following steps:
- Formulate research questions and develop hypotheses
- Design the study and collect data
- Choose an appropriate statistical test with an appropriate test statistic
- Verify that the data meet the assumptions for the chosen test
- Weigh up evidence against hypotheses
- Draw conclusion
- Decide whether to reject or retain the null hypothesis