Hypothesis Testing

Hypothesis Testing Overview

Key Concepts in Hypothesis Testing

  • Hypotheses Definition

    • Two types of hypotheses: Null Hypothesis (H₀) and Alternative Hypothesis (H₁ or Hₐ)

    • H₀: Represents a statement of no effect or no difference.

    • H₁: Represents a statement of an effect or a difference.

  • Symbols and Statements

    • Hypotheses can be expressed using symbols such as:

    • ≤ (less than or equal to)

    • < (less than)

    • ≥ (greater than or equal to)

    • > (greater than)

    • ≠ (not equal to)

Example Hypothesis Testing

  • Mean Attendance Example

    • Claim: The mean attendance (μ) is greater than or equal to 20,000.

    • Null Hypothesis: H₀: μ ≥ 20,000 (the claim about the mean is accepted).

    • Alternative Hypothesis: H₁: μ < 20,000 (the null is rejected).

Starting Point for Hypothesis Testing

  1. Understand the statement and translate it into statistical language.

  2. Define the null hypothesis (H₀) and alternative hypothesis (H₁).

    • Example from shipping department: "Number of errors < 3" translates to:

      • H₀: σ ≥ 3 (null hypothesis)

      • H₁: σ < 3 (alternative hypothesis)

  3. If the statement involves population standard deviation, it uses the symbol σ.

Lung Cancer Example

  • Claim: Lung cancer accounts for 25% of all diagnoses.

    • Null Hypothesis: H₀: p = 0.25

    • Alternative Hypothesis: H₁: p ≠ 0.25 (two-tailed test)

Types of Decisions in Hypothesis Testing

  • For H₀, there are only two possible outcomes:

    • Reject H₀: If sample provides sufficient evidence.

    • Fail to Reject H₀: If sample does not provide enough evidence.

  • Note: You can never support H₀. The only actions are to reject or fail to reject.

Errors in Hypothesis Testing

  • There are two types of errors that can occur:

    • Type I Error (α): Rejecting H₀ when it is actually true. This is a false positive.

    • Type II Error (β): Failing to reject H₀ when it is false. This is a false negative.

Level of Significance

  • Alpha (α): The probability threshold set to determine when to reject H₀.

    • Common values: 0.10, 0.05, 0.01.

  • A smaller α decreases the chance of Type I errors but increases the chance of Type II errors.

  • Every hypothesis test is based on these levels of significance.

p-Value and Decision Making

  • A p-value is the probability of obtaining the observed results, or something more extreme, given that H₀ is true.

    • For example: If H₀ is true, how extreme can my observed test statistic be?

  • Decision Rule: If p-value ≤ α, then reject H₀.

    • This means that the evidence is sufficiently strong against H₀.

Steps for Hypothesis Testing

  1. State the hypotheses (H₀ and H₁) using proper symbols and population parameters.

  2. Choose a level of significance (α).

  3. Collect data and calculate the test statistic (z-score).

  4. Calculate the p-value based on the test statistic.

  5. Compare the p-value to α to make the decision:

    • If p-value < α, reject H₀.

    • If p-value ≥ α, fail to reject H₀.

Calculation of z-Scores

  • The z-score can be calculated using the formula: z = \frac{\bar{x} - \mu}{\frac{\sigma}{\sqrt{n}}}

    • Where \bar{x} is the sample mean, μ is the population mean, σ is the population standard deviation, and n is the sample size.

Tail Analysis in Hypothesis Testing

  • One-tailed Tests:

    • Left-Tail Test: H₁ involves <; the extreme is to the left. Area to the left of z gives the p-value.

    • Right-Tail Test: H₁ involves >; the extreme is to the right. Area to the right of z gives the p-value.

  • Two-tailed Tests: H₁ involves ≠; you look at both tails (area to the left and right).

    • p-value is calculated by doubling the area from one side of the z-score.

Examples of Tail Cases

  • Example: Claim that mean time is no more than 102 seconds per day, which is:

    • Null hypothesis (H₀): μ ≤ 102

    • Alternative hypothesis (H₁): μ > 102 (Right-Tail Test).

Summary

  • Hypothesis testing is a structured method for making statistical conclusions. Key steps include forming hypotheses, calculating test statistics and p-values, determining a decision per the significance level, and being aware of potential errors. Understanding these concepts ensures accurate interpretations and decisions in statistical analyses.