Skip to content

Applied Mathematics · Ch 7 — Inferential Statistics

T- Test for Two Independent Groups

7.3.3

T- Test for Two Independent Groups

The two-sample (independent-groups) t-test extends the same logic to comparing two groups against each other — an experimental group against a control group, say — to check whether their means differ by more than random chance would explain. A typical hypothesis pair looks like:

H0:μ1=μ2H_0: \mu_1 = \mu_2 (the two population means are equal)

H1:μ1≠μ2H_1: \mu_1 \neq \mu_2 (the two population means are not equal)

The exact test statistic depends on whether the two populations are assumed to share the same variance.

Case 1 — variances assumed equal. The two samples are pooled into a single combined estimate of variability, SpS_p, before computing tt:

t=xˉ1−xˉ2Sp1n1+1n2,Sp=(n1−1)s12+(n2−1)s22n1+n2−2t = \dfrac{\bar{x}_1 - \bar{x}_2}{S_p\sqrt{\tfrac{1}{n_1} + \tfrac{1}{n_2}}}, \qquad S_p = \sqrt{\dfrac{(n_1-1)s_1^2 + (n_2-1)s_2^2}{n_1 + n_2 - 2}}

where s1s_1 and s2s_2 are the two sample standard deviations, and SpS_p (the pooled standard deviation) blends them into one combined estimate.

Case 2 — variances assumed unequal. No pooling is done; each sample's own variance is used directly:

t=xˉ1−xˉ2s12n1+s22n2t = \dfrac{\bar{x}_1 - \bar{x}_2}{\sqrt{\dfrac{s_1^2}{n_1} + \dfrac{s_2^2}{n_2}}}

Degrees of freedom also work differently in the two cases. Under equal variances, df=n1+n2−2df = n_1 + n_2 - 2. Under unequal variances, dfdf is computed from a more elaborate expression combining both sample variances and sizes, and is generally rounded down to a whole number.

As with the one-sample test, the calculated tt is compared against the critical tt value from the t-distribution table at the chosen confidence level and degrees of freedom — if the calculated value exceeds the critical value, the null hypothesis of equal means is rejected.

Critical t-Values (t-Distribution Table)

The table below lists the critical values of the tt-distribution, transcribed from the t-table printed in the chapter. The top row is the area in one tail (the significance level α\alpha for a one-tailed test); the italic row beneath it is the matching area in two tails (use it for a two-tailed test). Each row is a value of the degrees of freedom dfdf. To find a critical tt, read down to your dfdf and across to the appropriate α\alpha column; for a left-tailed test the value is negative, for a right-tailed test positive, and for a two-tailed test both signs (±\pm) apply. For example, at df=29df = 29 the two-tailed 0.050.05 critical value is ±2.045\pm 2.045, and the one-tailed 0.050.05 value is 1.6991.699.

dfdf / one-tail α\alpha0.0050.010.0250.050.10
(two-tail α\alpha)0.010.020.050.100.20
163.65731.82112.7066.3143.078
29.9256.9654.3032.9201.886
35.8414.5413.1822.3531.638
44.6043.7472.7762.1321.533
54.0323.3652.5712.0151.476
63.7073.1432.4471.9431.440
73.4992.9982.3651.8951.415
83.3552.8962.3061.8601.397
93.2502.8212.2621.8331.383
103.1692.7642.2281.8121.372
113.1062.7182.2011.7961.363
123.0552.6812.1791.7821.356
133.0122.6502.1601.7711.350
142.9772.6242.1451.7611.345
152.9472.6022.1311.7531.341
162.9212.5832.1201.7461.337
172.8982.5672.1101.7401.333
182.8782.5522.1011.7341.330
192.8612.5392.0931.7291.328
202.8452.5282.0861.7251.325
212.8312.5182.0801.7211.323
222.8192.5082.0741.7171.321
232.8072.5002.0691.7141.319
242.7972.4922.0641.7111.318
252.7872.4852.0601.7081.316
262.7792.4792.0561.7061.315
272.7712.4732.0521.7031.314
282.7632.4672.0481.7011.313
292.7562.4622.0451.6991.311
302.7502.4572.0421.6971.310
312.7442.4532.0401.6961.309
322.7382.4492.0371.6941.309
342.7282.4412.0321.6911.307
362.7192.4342.0281.6881.306
382.7122.4292.0241.6861.304
402.7042.4232.0211.6841.303
452.6902.4122.0141.6791.301
502.6782.4032.0091.6761.299
Figure 5.4Two-sample t-test: the obtained value t = −0.57 lies inside ±2.365, in the non-rejection region, so the null hypothesis is not rejected
Fig. 5.4 — Two-sample t-test: the obtained value t = −0.57 lies inside ±2.365, in the non-rejection region, so the null hypothesis is not rejected

Drawn by us to help you understand the concept clearly, and verified to make sure it's accurate. For exams, practice from your NCERT textbook's own diagram.

The obtained t = −0.57 lies inside ±2.365, in the do-not-reject region, so H₀ i …