Statistical Calculators › Means: One and Two Groups › Confidence Interval for the Difference Between Two Means
← All Calculators

Means: One and Two Groups

Confidence Interval for the Difference Between Two Means

Construct a confidence interval for the difference between two independent population means using the Welch-Satterthwaite method, which does not require the two population variances to be equal. Enter the sample means, standard deviations, sample sizes, and desired confidence level. Runs entirely in your browser.

Two Independent Samples

The interval estimates μ1 − μ2. Standard deviations are treated as unknown and unequal.

Confidence Interval

Welch-Satterthwaite interval for μ1 − μ2.
Enter the sample information and click Calculate Confidence Interval.

Methodology

This calculator constructs a two-sided confidence interval for the difference between two independent population means. It uses the individual-variance t procedure, also known as the Welch-Satterthwaite method, which is appropriate when the population standard deviations are unknown and are not assumed to be equal.

Point Estimate

The point estimate of the population mean difference is the difference between the two sample means:

Difference = x̄1 − x̄2

Standard Error

The standard error of the difference between the two independent sample means is:

SE = √(s12/n1 + s22/n2)

Welch-Satterthwaite Degrees of Freedom

Because the two variances are not assumed to be equal, the degrees of freedom are calculated using the Welch-Satterthwaite approximation:

ν = (s12/n1 + s22/n2)2 / [s14/(n12(n1−1)) + s24/(n22(n2−1))]

Confidence Interval

For a confidence level of 1 − α, the two-sided interval is:

(x̄1 − x̄2) ± t1−α/2,ν √(s12/n1 + s22/n2)

The resulting interval estimates the difference μ1 − μ2. If the interval contains zero, zero is among the values compatible with the specified confidence level and the observed data. If the entire interval is above or below zero, the estimated direction of the difference is correspondingly positive or negative.

Worked Validation Example

The following values provide a fixed numerical validation target: Group 1 has mean 4.7, standard deviation 9.3, and n = 18; Group 2 has mean 8.8, standard deviation 11.5, and n = 10. Using a two-sided 95% confidence interval gives a standard error of approximately 4.246175 and Welch-Satterthwaite degrees of freedom of approximately 15.635263.

Expected result: 95% CI = (−13.118585, 4.918585)

Expected t critical value: 2.123932

Expected mean difference: −4.100000

References

NCSS, LLC. (2022). Confidence Intervals for the Difference Between Two Means. PASS Sample Size Software, Chapter 471. The PASS documentation describes both the equal-standard-deviation and unequal-standard-deviation formulations and identifies the latter as the Welch-Satterthwaite method.

NIST/SEMATECH. e-Handbook of Statistical Methods: Difference of Means Confidence Interval. National Institute of Standards and Technology. The NIST formulation gives the confidence interval as the observed difference in means plus or minus the appropriate t critical value times the standard error, with the Welch-Satterthwaite degrees of freedom for unequal variances.

Welch, B. L. (1938). The significance of the difference between two means when the population variances are unequal. Biometrika, 29(3/4), 350–362.