VG

Chapter 8 Notes: Hypothesis Testing II

Chapter 8: Hypothesis Testing II: With Two Sample Means (or Proportions)

Outline

  • Introduction
  • Hypothesis Testing with Two Sample Means (Large Samples: z test)
  • Hypothesis Testing with Two Sample Proportions (Large Samples: z test)
  • The Limitations of Hypothesis Testing: Significance vs. Importance

Basic Logic

  • We want to determine if a real difference exists between the parameters of two populations.
  • We draw a random sample from each population and compare the sample statistics (means or proportions).
  • The general research question is: Based on the difference between the sample statistics, can we conclude that the two populations are significantly different?

Hypothesis Testing

  • H0 (Null Hypothesis): There is no real difference between the parameters of two populations.
  • H1 (Alternative Hypothesis): There is a real difference.
  • If the difference between the two sample statistics is very large, the chance of observing that difference, assuming H0 is true, will be very small (e.g., less than "alpha" = 0.05).
  • In this case, we reject H0 and accept H1, concluding that there is a significant (or real) difference between the two populations.

The Five-Step Model

  1. Make assumptions and meet test requirements.
  2. State null and research hypotheses.
  3. Select the sampling distribution and determine the critical region.
  4. Calculate the test statistic.
  5. Interpret results and make a decision.

Example 1: Hypothesis Testing with Two Sample Means

  • We want to know if middle-class families send and receive a different number of emails than working-class families.
  • We draw a random sample from each population.
  • Question: Is there a real or significant difference between these two types of families in terms of email usage?

Sample Data

  • Middle Class (Sample 1): Mean (\bar{X1}) = 8.7, Standard Deviation (S1) = 0.3, Sample Size (N_1) = 89
  • Working Class (Sample 2): Mean (\bar{X2}) = 5.7, Standard Deviation (S2) = 1.1, Sample Size (N_2) = 55

Step 1: Make Assumptions and Meet Test Requirements

  • Random and Independent Samples
  • The variable being tested (number of email messages) is Interval-Ratio Level.
  • The sampling distribution is approximately normal in shape because the number of cases in each sample and the combined number of cases in these two samples are large enough (N1 > 30 and N2 > 30).

Step 2: State the Null and Research Hypotheses

  • H0: \mu1 = \mu2 (i.e., \mu1 - \mu2 = 0) - No real difference between the means of the two populations.
  • H1: \mu1 \neq \mu2 (i.e., \mu1 - \mu2 \neq 0) - There is a real difference between the means of the two populations.

Step 3: Select Sampling Distribution and Establish the Critical Region

  • The sampling distribution of the differences in sample means is a normal distribution (Z distribution).
  • If setting "alpha" = 0.05, Z_{critical} = \pm 1.96 (two-tailed test).

Step 4: Compute the Test Statistic

z{obtained} = {\bar{X1} - \bar{X2} \over \sqrt{{S1^2 \over N1} + {S2^2 \over N_2}}} = {8.7 - 5.7 \over \sqrt{{0.3^2 \over 89} + {1.1^2 \over 55}}}

Step 5: Interpret Results and Make a Decision

  • Compare Z{critical} = \pm 1.96 and Z{obtained} = 19.8.
  • The Z_{obtained} falls in the Critical Region.
  • If H0 were true, it is very unlikely that we would find such a large difference between these two sample means.
  • Conclusion:
    • H0 must be false and should be rejected.
    • There is a significant difference between middle-class families and working-class families in regard to email usage.

Example 2: Hypothesis Testing with Two Sample Proportions

  • We want to know if middle-class families are more likely to have a computer at home than working-class families.
  • We draw a random sample from each population.
  • Question: Is there a real or significant difference between these two types of families in the likelihood of owning a computer?

Sample Data

  • Middle Class (Sample 1): Sample Proportion (P{s1}) = 0.81, Sample Size (N1) = 89
  • Working Class (Sample 2): Sample Proportion (P{s2}) = 0.51, Sample Size (N2) = 55

Step 1: Make Assumptions

  • Random sampling
  • The variable being tested is nominal-level (proportion of having a computer).
  • The sampling distribution is a normal distribution because the combined number of cases in these two samples is large (N1 + N2 > 100).

Step 2: Null & Alternative Hypotheses

  • H0: P{u1} = P{u2}
  • H1: P{u1} \neq P{u2}

Step 3: Establish the Critical Region

  • Setting "alpha" = 0.05
  • Z_{critical} = \pm 1.96 (two-tailed test)

Step 4: Compute the Test Statistic

z{obtained} = {(P{s1} - P{s2}) - (P{\mu1} - P{\mu2}) \over \hat{\sigma}{P-P}} = {(P{s1} - P{s2}) \over \sqrt{\hat{P}(1-\hat{P})({1 \over N1} + {1 \over N2})}}

Where:
\hat{P} = {N1P1 + N2P2 \over N1 + N2}

Step 5: Make a Decision

  • Z{critical} = 1.96, Z{obtained} = 3.8
  • We reject the H0. Middle-class families are more likely to have a computer at home than working-class families.

Factors Affecting Decision-Making

  • The size of the difference between sample statistics.
  • The alpha level: The larger the alpha, the more likely we are to reject the H0.
  • The use of one- vs. two-tailed tests: we are more likely to reject with a one-tailed test.
  • The sample size (N): The larger the sample, the more likely we are to reject the H0.

Significance vs. Importance

  • Significance is not the same thing as importance.
  • Differences that are otherwise trivial may be significant.
  • When working with large samples, even small differences may be significant.
  • The value of the test statistic (step 4) is an inverse function of N.
  • The larger the N, the greater the value of the test statistic, and the more likely it will fall in the critical region and be declared significant.

Homework and Lab Exercises

  • HW7 (graded): 8.6 & 8.8 (p. 230)
    • When the sample size is larger than 30 for both samples, we assume the concerned sampling distribution approximates a normal curve, and we can compute the obtained z score.
    • We focus on the two-tailed test, and the research/alternative hypothesis simply predicts the population means are different.
  • Lab 6 Exercise (ungraded): 8.4 (p. 229)
    • When the sample size is larger than 30 for both samples, we assume the concerned sampling distribution approximates a normal curve, and we can compute the obtained z score.
    • We focus on the two-tailed test, and the research/alternative hypothesis simply predicts the population means are different.