Test For Two Means

 

 

1) Independent t-test

 

For samples taken from two normal populations (n1 and n2) with different means m1 and m2 but identical variances s2

 

Calculate pooled standard deviation

 

Sp = Ö (n1-1)S12 + (n2-1)S22 / n1+n2 –2

 

Sp = pooled standard deviation (weighted average of the two samples variances)

 

 S2 = 1/n-1 [ Syi2 – (Syi)2 / n ]

 

If n1 = n2

 

Sp = (S12 + S22) / 2

 

 

t= ÿ 1 – ÿ 2 / Sp Ö 1/n1 + 1/n 2

 

 

df = n1 + n2 – 2

 

Ho: m1 = m2

 

Ha: 1. m1 > m2

       2. m1 < m2

       3. m1 ¹ m2

 

1.    Reject Ho if t > ta

2.    Reject Ho if t < ta

3.    Reject Ho if | t | > ta/2

 

 

Example

 

An experiment was conducted to compare the mean number of tapeworms in the stomachs of sheep that had been treated for worms against the mean number of those that were untreated. A sample of 14 worm-infected sheep was randomly divided into two groups. Seven were injected with the drug and the remainders were left untreated. After a period the number of worms were recorded

 

Treated       18   43   28   50   16   32   13

Untreated    40   54   26   63   21   37   39

 

Test the hypothesis that there is no difference in the mean number of worms between the treated and untreated sheep.

a = 0.05

 

 

 

 

2) Dependent t-test

 

Samples taken from two normal populations (n1 and n2) with different means m1 and m2 but different variances s2

 

t = ÿ1 – ÿ 2 / Ö S12/n1 + S22/n2

 

df = (n1-1)(n2-1) / (n2-1)c2 + (1-c)2(n1-1)

 

c = S12/n1 / S12/n1 + S22 /n2

 

Example

 

Treated               5     13     18     6     4     2     15 

Untreated           40   54     26     63   21   37