Two-Sample t-Test
Welch's two-sample t-statistic, Welch-Satterthwaite df, p-value, significance flag, and mean difference.
Example
You enter
- Group 1 mean 82
- Group 1 SD 6
- Group 1 n 25
- Group 2 mean 78
- Group 2 SD 7
- Group 2 n 22
- Tail two
- Alpha 0.05
You get
- T stat 2.089
- P value 0.043
Checked against published worked examples from: OpenIntro Statistics Ch. 7 (Welch's two-sample t).
Details, formula, and sources
ScopeReusing the bundled Student-t CDF.
Formula or tablet = (m1-m2)/sqrt(s1^2/n1 + s2^2/n2); Welch df = (s1^2/n1 + s2^2/n2)^2 / [ (s1^2/n1)^2/(n1-1) + (s2^2/n2)^2/(n2-1) ]; p from the Student-t CDF.
Source and editionPer OpenIntro Statistics Chapter 7 (inference for numerical data, Welch's t) and the Welch-Satterthwaite df, by name; the t-CDF reuses the bundled special-function helper.
Free accessFree at openintro.org.
What governsEstimate. AHJ and licensed professional govern.
API field namesmean1, sd1, n1, mean2, sd2, n2, tail, alpha, t_stat, p_value
- Welch's t does not assume equal variances; uses the Welch-Satterthwaite dfOpenIntro Ch. 7