Hypothesis Testing with z-Tests and t-Tests

Foundations of Hypothesis Testing: Z-Tests Versus T-Tests

  • The Central Limit Theorem establishes that as sample size increases, the sampling distribution of the sample mean approaches normality, regardless of the population distribution shape; a standard rule of thumb is that the Central Limit Theorem is reliably engaged at sample sizes of n≥30n \ge 30.

  • When the population standard deviation σ\sigma is known, the standard normal zz-distribution is used to calculate the test statistic:   z=xˉ−μσnz = \frac{\bar{x} - \mu}{\frac{\sigma}{\sqrt{n}}}

  • Assuming σ\sigma is known is generally unrealistic in practice; when σ\sigma is unknown, the sample standard deviation ss must be substituted, requiring a tt-test:   t=xˉ−μsnt = \frac{\bar{x} - \mu}{\frac{s}{\sqrt{n}}}

  • The procedural workflow for a hypothesis test remains identical whether using zz or tt:

    • State the null hypothesis (H0H_0) and alternative hypothesis (HaH_a).
    • Calculate the standardized test statistic (zz or tt).
    • Determine the pp-value from the appropriate distribution table (the standard normal zz-table for zz-statistics, or the Student's tt-table for tt-statistics).
    • Compare the pp-value to the designated level of significance α\alpha to reach a decision.
  • Structure and properties of statistical hypotheses:

    • The null hypothesis always takes the form of an equality: H0:μ=μ0H_0: \mu = \mu_0, asserting that the population parameter equals a specified baseline constant.
    • The alternative hypothesis represents the research claim and has three possible forms:
    • Directional lower tail: Ha:μ<μ0H_a: \mu < \mu_0
    • Directional upper tail: Ha:μ>μ0H_a: \mu > \mu_0
    • Non-directional two-tailed: Ha:μ≠μ0H_a: \mu \neq \mu_0
  • The sample mean xˉ\bar{x} must never appear in either H0H_0 or HaH_a. Hypotheses are claims about unknown population parameters (μ\mu), not sample statistics (xˉ\bar{x}).

One-Tailed Left-Sided Test: Adult Blood Phosphorus Levels

  • Biological context: Phosphorus levels in adult human blood follow a normal distribution with a known population mean μ=1.2 mmol/L\mu = 1.2\,\text{mmol/L} and a known population standard deviation σ=0.1 mmol/L\sigma = 0.1\,\text{mmol/L}.

  • Research premise: Older adults experience a higher incidence of bone fractures than the general adult population. To assess whether decreased bone density correlates with reduced phosphorus, a study evaluates whether blood phosphorus levels in older individuals are significantly lower than the general adult baseline of 1.2 mmol/L1.2\,\text{mmol/L}.

  • Sample parameters:

    • Target demographic: Older men and women between the ages of 7575 and 7979 years.
    • Sample size: n=12n = 12
    • Observed sample mean: xˉ=1.128 mmol/L\bar{x} = 1.128\,\text{mmol/L} (obtained by summing the 1212 individual clinical measurements and dividing by 1212
  • Hypothesis specification:

    • H0:μ=1.2 mmol/LH_0: \mu = 1.2\,\text{mmol/L}
    • Ha:μ<1.2 mmol/LH_a: \mu < 1.2\,\text{mmol/L}
  • Test statistic calculation:   z=1.128−1.20.112=−2.49z = \frac{1.128 - 1.2}{\frac{0.1}{\sqrt{12}}} = -2.49

  • Determination and interpretation of the pp-value:

    • Consulting the standard normal table for z=−2.49z = -2.49 yields a cumulative lower-tail probability of p=0.0064p = 0.0064 (or 0.64%0.64\%
    • Meaning of the pp-value: Assuming the null hypothesis is true (μ=1.2 mmol/L\mu = 1.2\,\text{mmol/L}), the probability of randomly obtaining a sample of n=12n = 12 with a mean of 1.128 mmol/L1.128\,\text{mmol/L} or lower purely by chance is less than 1%1\% (0.00640.0064
  • Decision at significance levels:

    • At α=0.05\alpha = 0.05: Because p=0.0064<0.05p = 0.0064 < 0.05, reject H0H_0.
    • At α=0.01\alpha = 0.01: Because p=0.0064<0.01p = 0.0064 < 0.01, reject H0H_0.
    • Conclusion: In both cases, the null hypothesis is rejected in favor of HaH_a. There is statistically significant evidence that adults aged 7575 to 7979 have an average blood phosphorus concentration lower than 1.2 mmol/L1.2\,\text{mmol/L}.

One-Tailed Right-Sided Test: Equine Blood Glucose Levels

  • Veterinary setting: Evaluation of an individual horse named Gentleman residing at a Colorado ranch.

  • Sample characteristics:

    • A veterinarian collected n=8n = 8 blood glucose measurements taken at random intervals over several weeks.
    • Units of measurement: mg/100 mL\text{mg} / 100\,\text{mL}
    • Sample mean: xˉ=92.3 mg/100 mL\bar{x} = 92.3\,\text{mg} / 100\,\text{mL}
  • Normality requirement and small-sample limitations:

    • Because n=8n = 8, the sample size is far below the threshold required for the Central Limit Theorem to guarantee normality (by contrast, a sample size such as n=65n = 65 would not require an assumption of normality).
    • Therefore, blood glucose measurements must explicitly be assumed to follow a normal distribution.
  • Population parameters:

    • Baseline mean for healthy horses: μ=85 mg/100 mL\mu = 85\,\text{mg} / 100\,\text{mL}
    • Population standard deviation: σ=15.2 mg/100 mL\sigma = 15.2\,\text{mg} / 100\,\text{mL}, representing the typical variation or average distance of individual readings from the population mean.
  • Research question: Do the observed veterinary data provide evidence that Gentleman's mean glucose concentration is higher than the standard baseline of 85 mg/100 mL85\,\text{mg} / 100\,\text{mL}?

  • Hypothesis specification:

    • H0:μ=85 mg/100 mLH_0: \mu = 85\,\text{mg} / 100\,\text{mL}
    • Ha:μ>85 mg/100 mLH_a: \mu > 85\,\text{mg} / 100\,\text{mL}
  • Test statistic calculation:   z=92.3−8515.28=1.36z = \frac{92.3 - 85}{\frac{15.2}{\sqrt{8}}} = 1.36

  • Determination and interpretation of the pp-value:

    • From the standard normal cumulative table, the area to the left of z=1.36z = 1.36 is 0.91310.9131.
    • Upper-tail probability: p=1−0.9131=0.0869p = 1 - 0.9131 = 0.0869 (or 8.69%8.69\%
    • Meaning of the pp-value: If Gentleman's true mean glucose level is 85 mg/100 mL85\,\text{mg} / 100\,\text{mL}, there is an 8.69%8.69\% probability of obtaining a sample mean of 92.3 mg/100 mL92.3\,\text{mg} / 100\,\text{mL} or higher across n=8n = 8 readings due to random sampling variability.
  • Decision and substantive interpretation:

    • Testing at α=0.05\alpha = 0.05: Because p=0.0869>0.05p = 0.0869 > 0.05, do not reject H0H_0.
    • Scientific rationale on hypothesis retention: Failing to reject H0H_0 does not prove that H0H_0 is correct, and statistics does not permit "accepting" the null hypothesis. The data simply provide insufficient evidence to conclude that the true mean exceeds 85 mg/100 mL85\,\text{mg} / 100\,\text{mL} at the chosen standard of evidence.

Two-Tailed Hypothesis Testing: Red Blood Cell Volume

  • Clinical background: Total red blood cell volume per body weight is a critical diagnostic marker in medicine. For healthy adults, the mean red blood cell volume is μ=28 mL/kg\mu = 28\,\text{mL/kg}. Volume measurements that are either abnormally low or abnormally high signify clinical pathology.

  • Patient profile and sample parameters:

    • Patient: Jenny, whose health is monitored closely.
    • Sample size: n=25n = 25 random blood tests.
    • Sample mean: xˉ=29.95 mL/kg\bar{x} = 29.95\,\text{mL/kg}
    • Population standard deviation: σ=4.75 mL/kg\sigma = 4.75\,\text{mL/kg}
    • Distribution assumption: Normal distribution.
  • Research question: Determine whether Jenny's average red blood cell volume is different (in either direction) from the healthy baseline of 28 mL/kg28\,\text{mL/kg}.

    • The word "different" designates a non-directional, two-tailed alternative hypothesis.
    • One-sided hypotheses introduce directional bias by presuming the direction of deviation prior to analysis; two-sided hypotheses eliminate directional bias by testing for significant divergence in either extreme.
  • Hypothesis specification:

    • H0:μ=28 mL/kgH_0: \mu = 28\,\text{mL/kg}
    • Ha:μ≠28 mL/kgH_a: \mu \neq 28\,\text{mL/kg}
  • Test statistic calculation:   z=29.95−284.7525=1.954.755=1.950.95=2.05z = \frac{29.95 - 28}{\frac{4.75}{\sqrt{25}}} = \frac{1.95}{\frac{4.75}{5}} = \frac{1.95}{0.95} = 2.05

  • Determination of the two-tailed pp-value:

    • Lower tail boundary: z=−2.05z = -2.05 corresponds to a cumulative area of 0.02020.0202.
    • Because the alternative hypothesis is two-sided, the tail area must be doubled to account for extremes at both ends of the distribution:     p=2×0.0202=0.0404p = 2 \times 0.0202 = 0.0404
    • This represents the combined probability of obtaining a sample mean as high as 29.95 mL/kg29.95\,\text{mL/kg} (an excess of +1.95 mL/kg+1.95\,\text{mL/kg}) or as low as 26.05 mL/kg26.05\,\text{mL/kg} (a deficit of −1.95 mL/kg-1.95\,\text{mL/kg}, contextualized as values below 27.05 mL/kg27.05\,\text{mL/kg}) if the true mean is 28 mL/kg28\,\text{mL/kg}.
  • Evaluation against multiple significance thresholds:

    • Testing at α=0.05\alpha = 0.05:
    • Because p=0.0404<0.05p = 0.0404 < 0.05, reject H0H_0.
    • The result is designated as statistically significant at the 5%5\% level.
    • Testing at α=0.01\alpha = 0.01:
    • Because p=0.0404>0.01p = 0.0404 > 0.01, do not reject H0H_0.
    • The result is not statistically significant at the 1%1\% level.

Statistical Error Analysis and Decision Matrices

  • In hypothesis testing, exactly two types of inferential errors can occur:

    • Type I Error: Rejecting the null hypothesis (H0H_0) when H0H_0 is actually true (a false positive error).
    • Type II Error: Failing to reject the null hypothesis (H0H_0) when the alternative hypothesis (HaH_a) is true (a false negative error).
  • Decision matrix breakdown:

    • When H0H_0 is True in reality:
    • Action: Reject H0H_0 →\rightarrow Type I Error; the probability of this error is α\alpha (located in the top-left quadrant of the decision matrix).
    • Action: Do Not Reject H0H_0 →\rightarrow Correct Decision; the probability of this outcome is 1−α1 - \alpha (located in the bottom-left quadrant).
    • Column total: α+(1−α)=1.00\alpha + (1 - \alpha) = 1.00 (100%100\%
    • When HaH_a is True in reality (H0H_0 is False):
    • Action: Reject H0H_0 →\rightarrow Correct Decision; known as the Power of the Test, with probability 1−β1 - \beta (located in the top-right quadrant).
    • Action: Do Not Reject H0H_0 →\rightarrow Type II Error; the probability of this error is β\beta (located in the bottom-right quadrant).
    • Column total: β+(1−β)=1.00\beta + (1 - \beta) = 1.00 (100%100\%
  • Definition and scope of test power:

    • The power of a statistical test is defined as 1−β1 - \beta, representing the probability of correctly rejecting a false null hypothesis.
  • Practical and probabilistic meaning of α\alpha:

    • The significance level α\alpha represents the precise threshold of acceptable risk for making a Type I error.
    • Setting α=0.05\alpha = 0.05 signifies that a researcher accepts a 5%5\% probability of rejecting H0H_0 when H0H_0 is actually true. Under repeated sampling where H0H_0 holds, the test will erroneously reject H0H_0 5%5\% of the time.
    • Setting α=0.01\alpha = 0.01 tightens this criterion, requiring more extreme sample evidence such that a true null hypothesis will be erroneously rejected only 1%1\% of the time.

Questions and Discussion

  • Identification of the null parameter in adult phosphorus testing:

    • Question: What numerical value defines the null hypothesis for average adult phosphorus?
    • Response: 1.2 mmol/L1.2\,\text{mmol/L}.
  • Alternative hypothesis direction in adult phosphorus testing:

    • Question: What is the alternative hypothesis based on the research claim that older individuals experience bone fractures?
    • Response: Less than 1.2 mmol/L1.2\,\text{mmol/L} (Ha:μ<1.2 mmol/LH_a: \mu < 1.2\,\text{mmol/L}.
  • Baseline parameter in equine glucose testing:

    • Question: What is the null parameter for average equine glucose levels?
    • Response: 85 mg/100 mL85\,\text{mg} / 100\,\text{mL}.
  • Alternative hypothesis formulation for equine glucose testing:

    • Question: How is the alternative hypothesis structured if testing whether Gentleman's average is elevated?
    • Response: Greater than 85 mg/100 mL85\,\text{mg} / 100\,\text{mL} (Ha:μ>85 mg/100 mLH_a: \mu > 85\,\text{mg} / 100\,\text{mL}.
  • Table lookup for standard normal test statistic:

    • Question: What is the cumulative area from the standard normal table for a zz-score of 1.361.36?
    • Response: 0.91310.9131.
  • Decision rule application for equine glucose data:

    • Question: At α=0.05\alpha = 0.05, given a pp-value of 0.08690.0869, is the null hypothesis rejected or not rejected?
    • Response: Do not reject H0H_0.
  • Null hypothesis retention versus acceptance:

    • Question: When evidence is insufficient to reject H0H_0, is H0H_0 accepted as true?
    • Response: No. H0H_0 is never accepted; there is merely insufficient evidence to prove it incorrect.
  • Location of Type I error in the decision matrix:

    • Question: Which box in the decision table corresponds to α\alpha (the probability of a Type I error)?
    • Response: The top-left box.
  • Evaluation of statistical significance across multiple thresholds:

    • Question: In Jenny's two-tailed test with p=0.0404p = 0.0404, what are the conclusions at α=0.05\alpha = 0.05 and α=0.01\alpha = 0.01?
    • Response: At α=0.05\alpha = 0.05, reject H0H_0 (statistically significant). At α=0.01\alpha = 0.01, do not reject H0H_0 (not statistically significant).