0% found this document useful (0 votes)
24 views9 pages

ST130 - CHP 11

This chapter explains how to test the equality of two population means using the z-test and t-test. The z-test can be used to compare two independent sample means when the population standard deviations are known. Examples are provided to demonstrate how to perform hypothesis tests to evaluate if two population means are equal or different.

Uploaded by

Shikha Nand
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views9 pages

ST130 - CHP 11

This chapter explains how to test the equality of two population means using the z-test and t-test. The z-test can be used to compare two independent sample means when the population standard deviations are known. Examples are provided to demonstrate how to perform hypothesis tests to evaluate if two population means are equal or different.

Uploaded by

Shikha Nand
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

CHAPTER 11:

TESTING THE EQUALITY OF


TWO POPULATION MEANS

Chapter 11: Testing the Equality of Two Population Means 157


Overview
This chapter explains the hypothesis testing of the equality of two population means. The concepts
discussed in this chapter are z− test and the t−test for testing two population means. The chapter
concludes with a summary and a set of exercises.

Objectives
After completing this chapter, you should be able to:
1. Test the difference between two sample means using, the z-test.
2. Test the difference between two means for independent samples, using the t-test.

11.1 Introduction
The basic concepts of hypothesis testing were explained in Chapter 8. With the z and t tests, a sample
mean or proportion can be compared to a specific population mean or proportion.

There are, however, many instances when the researchers wish to compare two sample means, using
experiments and control groups. For example, the average lifetimes of two different brands of bus tires
might be compared to see whether there is any difference in the tread wear. Two different brands of
fertilizer might be tested to see whether one is better than the other for growing plants.

In comparing of the means, the same basic steps for hypothesis testing are used and z and t-tests are
also used. When comparing two means by using t-test, the researcher must decide whether the samples
are independent or dependent.

11.2 z-test for two Means


Researchers often want to compare two population means using two samples drawn from the
populations. For example, a researcher wishes to know whether there is a difference in the average age
of students enrolled at USP On-Campus (OC) and those enrolled through Distance and Flexible Learning
(DFL)? Then, the hypotheses to be tested are:
H 0 : 1  2 H 0  1  2  0
or
H1 : 1  2 H1  1  2  0
Where,
1  mean age of students enrolled OC
2  mean age of students enrolled through DFL

To test the difference between two means we have to know whether the two samples drawn from the
populations are dependent or independent, large or small and the population standard deviations
known or unknown.

11.2.1 Dependent and Independent Samples


Two samples drawn from two populations are independent if the selection of one sample from one
population does not affect the selection of the second sample from the second population. Otherwise,
the samples are dependent. Suppose we would like to compare the mean salaries of male and female
staffs in USP. Then, the samples must be drawn separately from two distinct groups, all males in USP
and all females in USP. These samples are known as independent samples. If we would wish to study

Chapter 11: Testing the Equality of Two Population Means 158


whether a new drug is effective in controlling a disease, two samples are taken before and after the use
of drug from the same unit. These samples are known as dependent samples.

11.2.2 Hypothesis
If we wish to decide whether the means of the populations from where two independent samples were
selected are really different or same, then the null hypothesis is H 0 : 1  2 (i.e. the means are not
different) and the alternative hypothesis could be any one of the following:

(i) H1 : 1  2 (two-tailed test)


or, (ii) H1 : 1  2 (left-tailed test)
or, (iii) H1 : 1  2 (right-tailed test)

Assumptions for the z-test


 Both samples are random samples and independent of each other.
 The standard deviation of both samples must be known and if the sample sizes are less than
30, the population must be normally distributed.

Test Statistic
The value of test statistic if 1 and 2 are known:

z
X 1  X 2    1   2 
.
 12  22

n1 n2

If 1 and 2 are known but the sample sizes are small (population normally distributed) the value of test
statistic will be same.

Confidence Interval Formula


Confidence interval for the difference between two means in the above cases can be found by:

 12  22  12  22
 X 1  X 2   Z /2 n1

n2
 1   2   X 1  X 2   Z /2
n1

n2
.

Chapter 11: Testing the Equality of Two Population Means 159


EXAMPLE 11−1

A survey found that the average hotel room rate in FJ is $88.42 and the average room rate in NZ is
$80.61. Assume that the data were obtained from two samples of 50 hotels each and that the population
standard deviations were $5.62 and $4.83 respectively. At  = 0.05, can it be concluded that there is no
significant difference in the rates?

SOLUTION

We need to test here, 1 2 (claim), which should be stated in null hypothesis.

Step 1: State the hypothesis


H 0 : 1  2 (claim)
H1 : 1  2

Step 2: Find the critical value.


Since = 0.05 and the test is two–tailed, using the standard normal tables we get critical values as
z = +1.96 See the diagram below.

Critical region Critical region


Acceptance
region

−1.96 1.96

Step 3: Compute the test statistics value


Given that X 1  88.42 , X 2  80.61 ,  1  5.62 ,  2  4.83 , n1  50 , and n2  50 . Since the sample
sizes are large, the test statistics value is:

z
X 1  X 2    1  2 

 8842  8061  0  745
 2
 2
5622  4832
1
 2
50 50
n1 n2

Step 4: Make a decision.


Since the test value z=7.45, falls in rejection region, the decision is: “reject H 0 ”. Hence, it be concluded
that there is significant difference in the rates.

Chapter 11: Testing the Equality of Two Population Means 160


EXAMPLE 11−2

Solve Example 11-1 using:


A. P-value method.
B. Confidence Interval method.

SOLUTION

A. The P-value is approximately equal to 0. Since the P-value is less than 0.05, we reject null hypothesis.
B. Since α = 0.05, we have to construct 95% confidence level of 1  2 . Substituting into the formula
one gets:
 8842  8061  1.96 5622  4832       8842  8061  1.96 5622  4832
1 2
50 50 50 50
5.76  1   2  9.86.

Since the confidence interval does not contain zero, one would reject the null hypothesis.

EXAMPLE 11−3

The data shown are the rental fees (in dollars) for two random samples of apartment in a large city. At
𝛼 = 0.10, can it be concluded that the average rental fees for apartments in the east are greater than
the average rental fee in the west? Assume  1  119 and  2  103 .

East West
495 390 540 445 420 525 400 310 375 750
410 550 499 500 550 390 795 554 450 370
389 350 450 530 350 385 395 425 500 550
375 690 325 350 799 380 400 450 365 425
475 295 350 485 625 375 360 425 400 475
275 450 440 425 675 400 475 430 410 450
625 390 485 550 650 425 450 620 500 400
685 385 450 550 425 295 350 300 360 400

SOLUTION

We need to test here, 1   2 (claim), which should be stated in alternate hypothesis.


Step 1: State the hypothesis
H 0 : 1   2
H 1 : 1   2 (claim)
Step 2: Find the critical value.

Chapter 11: Testing the Equality of Two Population Means 161


Since   01 and the test is right–tailed, using the standard normal tables we get critical value as z =
1.28. See the diagram below.

Critical
Acceptance
region
region

1.28

Step 3: Compute the test statistics value


Given that X 1  477.43 , X 2  437.35 ,  1  119 ,  2  103 , n1  40 , and n2  40 . Since the
sample sizes are large, the test statistics value is:

z
X 1  X 2    1  2 

 477.43  437.35  0  1.61
 12  22 1192  1032
 40 40
n1 n2

Step 4: Make a decision


Since the test value z=1.61, falls in rejection region, the decision is: “Reject H 0 ”. It can be concluded
that average rental fees for the east apartments is greater than the average rental fees for the west
apartment.

11.3 t-test for Two Means (Independent Samples)


We will use t-test for testing the hypotheses, if the following two conditions are satisfied:
 Population standard deviations are unknown and unequal.
 If the samples are small (i.e. n1  30 and n2  30 ), then the populations from which the
samples are drawn are normally distributed.
 Samples are independent.

Test Statistic
The value of test statistic is:

t
X 1  X 2    1  2 
s12 s22

n1 n2

The degrees of freedom (d.f) is equal to the smaller of n1  1 and n2  1.

Chapter 11: Testing the Equality of Two Population Means 162


Confidence Interval Formula
Confidence interval for the difference between two means in this case is:

s12 s22 s 2 s2
X 1  X 2   t /2   1  2   X1  X 2   t /2 1  2 .
n1 n2 n1 n2

The degrees of freedom (d.f) is equal to the smaller of n1  1 and n2  1.

EXAMPLE 11−4

The average size of a farm in Ba is 191 acres. The average size of a farm in Nadi is 199 acres. Assume
the data were obtained from two samples with standard deviations of 32 and 12 acres, respectively and
sample sizes 8 and 10, respectively. Can it be concluded at  = 0.05 that the average size of the farm
in the two districts in Fiji is different? Assume the populations are normally distributed.

SOLUTION

We need to test here, 1   2 (claim), which should be stated in alternate hypothesis.

Step 1: State the hypothesis


H 0 : 1   2
H 1 : 1   2 (claim)

Step 2: Find the critical value.


Since  = 0.05 and the test is two–tailed, using the t-distribution table from the Eton tables with d.f =
8−1=7 and 2p = 0.0.5 we get critical value as t = + 2.365. See the diagram below.

Critical Critical
region Acceptance region
region

−2.365 2.365

Step 3: Compute the test statistics value


Given that X 1  191 , X 2  199 , s1  38 , s2  12 , n1  8 , and n2  10 . Since the population
standard deviations are unknown, the test value is

t
X 1  X 2    1   2 

191  199   0
 0.67.
s12 s22 322  122
 8 10
n1 n2

Chapter 11: Testing the Equality of Two Population Means 163


Step 4: Make a decision
Since the test value t=-0.67, falls in acceptance region, the decision is: “do not reject H 0 ”. There is not
enough evidence to support the claim that the average size of the farm in the two districts in Fiji is different.

EXAMPLE 11−5

The mean age of a sample of 25 people who were playing soccer is 48.7 years, and standard deviation
is 6.8 years. The mean age of a sample of 35 people who were playing rugby is 55.3 years with a standard
deviation is 3.2 years. Can it be concluded at  = 0.05 that the mean age of those playing soccer is less
than those playing rugby. Assume the populations are normally distributed.

SOLUTION

We need to test here, 1   2 (claim), which should be stated in alternate hypothesis.


Step 1: State the hypothesis
H 0 : 1   2
H 1 : 1   2 (claim)

Step 2: Find the critical value.


Since  = 0.05 and the test is left–tailed, using the t-distribution table from the Eton tables with d.f =
25−1=24 and p = 0.05 we get critical value as t = −1.711 See the diagram below.

Critical Acceptance
region region

−1.711

Step 3: Compute the test statistics value

t
X 1  X 2    1   2 

 48.7  55.3  0
 4.509.
s12 s22 6.82  3.22
 25 35
n1 n2

Step 4: Make a decision


Since the test value t=-4.509, falls in critical region, the decision is: “Reject H 0 ”. There is enough
evidence to support the claim that the mean age of those playing soccer is less than those playing rugby.

Chapter 11: Testing the Equality of Two Population Means 164


11.4 Summary
This chapter explains the hypothesis testing of the equality of two population means. The concepts
discussed in this chapter are z-test and the t-test for testing two population means.

EXERCISES

1. A researcher claims that the average yearly earnings of male college graduates (with at least a
bachelor’s degree) is different from the average yearly earnings of female college graduates with the
same qualifications. Based on the results below, can it be concluded that there is difference in mean
earnings between male and female college graduates? Use the 0.01 level of significance.

Male Female
Sample mean $59,235 $52,487
Population standard deviation $8,945 $10,125
Sample size 40 35

2. A researcher wishes to see if there is a difference in the cholesterol levels of two groups of men. A
random sample of 30 men between the ages of 25 and 40 is selected and tested; the average
cholesterol level was 223 with standard deviation of 6.1. A second sample of 25 men between ages
of 41 and 56 is selected and tested; the average cholesterol level for this group was 229 with standard
deviation of 5.8. Assume the populations are normally distributed and the population standard
deviations are unequal. At   0.01, is there a difference in the cholesterol levels between the two
groups? Use traditional method.

3. The mean height of 20 male athletes in Fiji was 68.2 inches, while 20 male non- athletes in Fiji had
a mean height of 67.5 inches and that the population standard deviations were 2.5 inches and 2.8
inches, respectively. Assume the populations are normally distributed. Test the hypothesis that
athletes are taller than non- athletes at 5% level of significance, using:
A. P-value method.
B. Verify the solution in Part A using confidence interval method.

4. A sample of 35 chemists from Lautoka city shows an average salary of $39,420 with a standard
deviation of $1659, while a sample of 40 chemists from Suva city has an average salary of $30,215
with a standard deviation of $4116. Is there a significant difference between the two cities chemists’
salaries at   0.02?

5. A researcher claims that the mean of the salaries of primary school teachers is greater than the mean
of the salaries of secondary school teachers in Fiji. The mean of the salaries of a sample of 26 primary
school teachers is $48,256, and the sample standard deviation is $3,912.40. The mean of the salaries
of a sample of 24 secondary school teachers is $45,633, and the sample standard deviation is
$5,533. Assume the populations are normally distributed and the population standard deviations are
unequal. At = 0.05 can it be concluded that the mean of the salaries of the primary school teachers
is greater than the mean of the salaries of the secondary school teachers?

Chapter 11: Testing the Equality of Two Population Means 165

You might also like