T-Test for Two Independent Samples (Week 9)
Purpose:
The independent-measures (two-sample) t test is used to determine whether two independent groups (different participants in each group) have significantly different means on some variable.
i.e, to compare the means of two separate groups (like high- vs. low-creativity participants) to see if there’s a real difference.
Key concepts:
1. Independent Samples Design
Two separate groups are compared (e.g., paper vs. plastic plates, “smashed into” vs. “hit” wording).
Each participant contributes one score to one group only.
2. Hypotheses
Null hypothesis (H₀): μ₁ = μ₂
→ No difference between population means.Alternative hypothesis (H₁): μ₁ ≠ μ₂
→ There is a difference between population means.
3. Formula for the Test Statistic
t = (M₁ − M₂) / s₍M₁−M₂₎
where the standard error is:
s₍M₁−M₂₎ = √[ sₚ² * (1/n₁ + 1/n₂) ]
and the pooled variance is:
sₚ² = [ (n₁ − 1)s₁² + (n₂ − 1)s₂² ] / (n₁ + n₂ − 2)
4. Degrees of freedom:
Degrees of freedom (df) are related to how much data you have — basically, the number of values that can vary.
For a two-sample test,
df = (n₁ - 1) + (n₂ − 1)
More df = more data = more trust in your results.
We use the df to find the critical t-value from a chart or computer — that’s the cutoff to decide if your result is significant.
5. Decision Rule:
Compare the calculated t value to the critical t from a t-table using the chosen α (usually .05, two-tailed).
If p < .05 → Reject H₀ (significant difference).
If p ≥ .05 → Fail to reject H₀ (no significant difference).
6. Measures of Effect Size:
r²: (Proportion of variance)
formula: r² = t² / (t² + df)
An effect size tells you how big the difference is between groups, independent of sample size. It describes how much of the variability in scores is explained by group differences.
Values range from 0 to 1:
.01 → small effect
.09 → medium effect
.25 → large effect
7. Cohen’s d formula:
Cohen’s d tells you how many standard deviations apart the two group means are.
Standardized mean difference formula: d = (M₁ − M₂) / sₚ
Terminology/Recap:
t-statistic (t-value): Measures how big the difference is relative to variability.
Degrees of freedom (df): Relates to your sample sizes; tells you which t-distribution to use.
P-value: Probability that the difference could happen by chance. (i.e, the p-value is the probability that you would get a difference this big (or bigger) if there were actually no real difference between groups.)
If p < .05, it means there’s less than a 5% chance the result is just random → we call it statistically significant.
To get a p-value, compare the t-statistic to the values in the calculator the professor provided/t-distribution table, using degrees of freedom for an independent-measures (two-sample) t-test.(df=(n1−1)+(n2−1)).
Significance: Compare p-value to alpha (usually 0.05) to decide if the difference is meaningful.
Effect size (Cohen’s d): Shows how large the difference is in a standardized way.
Interpreting Results in APA Format:
To determine whether food waste differed by plate material, an independent-samples t-test was performed. The test was statistically significant, t(14) = 2.45, p = .028. The results show that participants who received their donuts on paper plates wasted significantly more food than those served on plastic plates.
(prof reference format)
(prof offers a excel calc for calculating stats in this weeks assignment from textbook)