One-sided vs two-sided tests

    Understanding One-Sided vs. Two-Sided Tests in Hypothesis Testing

    In hypothesis testing for proportions, a crucial decision involves determining whether your alternative hypothesis (Ha) should be one-sided or two-sided. This choice dictates how you calculate your p-value and interpret the results.

    The Null and Alternative Hypotheses

    Recall that the null hypothesis (H0) always states there is no effect, no difference, or no relationship—often expressed as a population proportion (p) being equal to a specific value (p0), e.g., H0: p = 0.50.

    The alternative hypothesis (Ha) is what you are trying to find evidence for. It challenges the null hypothesis and can take three forms:

    • Ha: p < p0 (one-sided, left-tailed)
    • Ha: p > p0 (one-sided, right-tailed)
    • Ha: p ≠ p0 (two-sided)

    One-Sided Tests (Directional)

    A one-sided test is used when you are specifically interested in detecting a deviation from the null hypothesis in only one direction. Your research question or prior knowledge strongly suggests that the true proportion is either strictly greater than or strictly less than the hypothesized value.

    • When to use:
      • You want to know if a new drug increases the cure rate (Ha: p > p0).
      • You want to know if a new policy decreases the crime rate (Ha: p < p0).
      • There's a specific, directional claim to test.
    • P-value calculation: For a one-sided test, the p-value is the probability of observing a sample statistic as extreme as, or more extreme than, the one calculated, in the hypothesized direction. For example, if Ha: p > p0 and your sample proportion is &hat;p, the p-value is P(Z > z*), where z* is your calculated test statistic.

    Two-Sided Tests (Non-Directional)

    A two-sided test is used when you are interested in detecting a deviation from the null hypothesis in either direction—that is, the true proportion could be either greater than or less than the hypothesized value. This is often the default choice when there is no strong prior reason to suspect a particular direction of difference.

    • When to use:
      • You want to know if a coin is biased (Ha: p ≠ 0.50).
      • You want to know if a new teaching method results in a different pass rate (Ha: p ≠ p0).
      • You're simply looking for any significant difference from the null value.
    • P-value calculation: For a two-sided test, the p-value is the probability of observing a sample statistic as extreme as, or more extreme than, the one calculated, in either direction. This means you calculate the probability for one tail (e.g., P(Z > |z*|)) and then multiply it by two. So, p-value = 2 * P(Z > |z*|) or 2 * P(Z < -|z*|).

    Consequences of the Choice

    The choice between one-sided and two-sided tests directly impacts the p-value and thus the conclusion of your test. A one-sided test will yield a p-value that is half the size of a two-sided test's p-value (if the sample statistic is in the direction of the alternative hypothesis). This means it is 'easier' to reject the null hypothesis with a one-sided test, given the same sample data and significance level (alpha). Therefore, the choice of alternative hypothesis must be made before analyzing the data, based on the research question, to avoid inflating the significance of the results.

    Practice questions

    1

    A researcher claims that more than 60% of consumers prefer brand A. Which type of alternative hypothesis should be used?

    2

    If a hypothesis test for a proportion yields a p-value of 0.03 for a two-sided test, what would the p-value be if the researcher had instead conducted an appropriate one-sided test (assuming the sample data supported that direction)?

    3

    A factory manager wants to determine if the proportion of defective items is different from the historical 5%. What kind of alternative hypothesis is appropriate?

    4

    Why is it important to choose between a one-sided and two-sided test before collecting or analyzing data?

    Practice more free →

    Free AP4U account — unlimited practice, AI grader, and progress tracking.

    Canonical: https://apforu.com/ap/statistics/unit-6-inference-for-categorical-data-proportions/one-sided-vs-two-sided-tests