How to Test Statistical Hypotheses
This lesson describes a general procedure that can be used to test statistical hypotheses.
How to Conduct Hypothesis Tests
A hypothesis test is a formal process for determining whether or not to reject a null hypothesis, based on sample data. All hypothesis tests are conducted the same way, following these five steps.
- State the hypotheses. Every hypothesis test requires the analyst to state a null hypothesis and an alternative hypothesis. The hypotheses are stated in such a way that they are mutually exclusive. That is, if one is true, the other must be false; and vice versa.
- Choose the significance level (aka, alpha or α). The significance level sets the threshold for statistical significance (e.g., α = 0.05 or α = 0.01).
-
Compute the test statistic. Choose an appropriate statistical test based on the type of data and the hypothesis being tested.
Use sample data to compute the test statistic (e.g., t-score, z-score, chi-square).
-
When the null hypothesis involves
a mean or proportion, use either of the
following equations to compute the test statistic.
Test statistic = (Statistic - Parameter) / (Standard deviation of statistic)
Test statistic = (Statistic - Parameter) / (Standard error of statistic)
where Parameter is the value appearing in the null hypothesis, and Statistic is the point estimate of the Parameter, based on sample data. (As part of the analysis, you will need to compute the standard deviation or standard error of the statistic. We provide those formulas as needed in future lessons.) - When the parameter in the null hypothesis involves categorical data, you may use a chi-square statistic as the test statistic. Instructions for computing a chi-square test statistic will be presented in future lessons (e.g., chi-square goodness of fit test).
-
When the null hypothesis involves
a mean or proportion, use either of the
following equations to compute the test statistic.
- Find the P-value. The P-value is the probability of observing a
sample statistic as extreme as the test statistic, assuming
the null hypothesis is true.
- For a one-tailed test. Find the probability of seeing a sample statistic greater than the absolute value of the test statistic. That is the P-value.
- For a two-tailed test. Find the probability of seeing a sample statistic greater than the absolute value of the test statistic. Multiply that probability by 2 (to account for positive and negative extreme values). That is the P-value.
The P-value for a one-tailed test is half of the P-value for a two-tailed test.
- Interpret results. Compare the P-value to the significance level (α). If the P-value is less than alpha, reject the null hypothesis.
Applications of the General Hypothesis Testing Procedure
The next few lessons show how to apply the general hypothesis testing procedure to different kinds of statistical problems.
- Proportions
- Difference between proportions
- Means
- Difference between means
- Difference between matched pairs
- Goodness of fit
- Homogeneity
- Independence
- Regression slope
At this point, don't worry if the general procedure for testing hypotheses seems a little bit unclear. The procedure will be clearer as you see it applied in the next few lessons.
Test Your Understanding
Problem 1
In hypothesis testing, which of the following statements is always true?
(A) The P-value is greater than the significance level.
(B) The P-value is computed from the significance level.
(C) The P-value is the parameter in the null hypothesis.
(D) The P-value is a test statistic.
(E) The P-value is a probability.
Solution
The correct answer is (E). The P-value is the probability of observing a sample statistic as extreme as the test statistic. It can be greater than the significance level, but it can also be smaller than the significance level. It is not computed from the significance level, it is not the parameter in the null hypothesis, and it is not a test statistic.