20
Statistics 8.4 Statistics 8.4 8.4 Testing the Difference Between Proportions Statistics Mrs. Spitz Spring 2009

Statistics 8.4 8.4 Testing the Difference Between Proportions Statistics Mrs. Spitz Spring 2009

Embed Size (px)

Citation preview

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

8.4 Testing the Difference Between Proportions

Statistics

Mrs. Spitz

Spring 2009

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Objectives/Assignment

• How to perform a z-test for the difference between two population proportions p1 and p2.

Assignment: pp. 404-406 #1-12

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two Sample z-Test for the Difference Between Proportions

• In this section, you will learn how to use a z-test to test the difference between two population proportions p1 and p2 using a sample proportion from each population. For instance, suppose you want to determine whether the proportion of female college students who earn a bachelor’s degree in four years is different from the proportion of male college students who earn a bachelor’s degree in four years.

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two Sample z-Test for the Difference Between Proportions

• To use a z-test to test such a difference, the following conditions are necessary:

1. The samples must be independent.

2. The samples must be large enough to use a normal sampling distribution. That is:

n1p1 ≥ 5, n1q1 ≥ 5, n2p2 ≥ 5, n2q2 ≥ 5

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two Sample z-Test for the Difference Between Proportions

• If these conditions are met, then the sampling distribution for the difference between the sample proportions, is a normal distribution with mean:

,ˆˆ 21 pp

21ˆˆ 21pppp And a standard error

2

22

1

11ˆˆ 21 n

qp

n

qppp

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two sample z-test for difference between proportions

• Notice that you need to know the population proportions to calculate the standard error. Because a hypothesis test for p1 - p2 is based on the condition of equality that p1 = p2 , you can calculate a weighted estimate of p using:

21

21

nn

xxp

111 p̂nx and 222 p̂nx where

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two-Sample z-Test for the Difference Between Proportions

• Using the weighted estimate , the standard error of the sampling distribution for is:,ˆˆ 21 pp

)11

(21

ˆˆ 21 nnqppp where

pq 1

Also, when determining whether the z-test can be used for the difference between proportions, you should use in place of p1 and p2 and in place of q1 and q2q

p

p

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Two Sample z-Test for the Difference Between Proportions

If the sampling distribution for is normal, you can use a two-sample z-test to test the difference between two population proportions, and

,ˆˆ 21 pp

1p 2p

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

If the null hypothesis states that p1 = p2, then the expression, p1 - p2 is equal to 0 in the preceding test.

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Ex. 1: A Two-Sample z-Test for the Difference Between Proportions

• In a study of 200 adult female and 250 adult male Internet users, 30% of the females and 38% of the males said that they plan to shop online at least once during the next month. At = 0.10, test the claim that there is a difference in the proportion of female Internet users who plan to shop online and the proportion of male Internet users who plan to shop online.

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• You want to determine whether there is a difference in the proportions. So, the null and alternative hypotheses are:

Ho: p1 = p2 and p1 p2 (claim)

Because the test is two-tailed and the level of significance is = 0.10, the critical values are 1.645. The rejection regions are z < -1.645 and z > 1.645.

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• The weighted estimate of the population proportion is:

21

21

nn

xxp

344.0450

155

250200

9560

p

• And . Because 200(0.344), 200(0.656),

250(0.344) and 250)0.656 are at least 5, you can use the two-sample z-test.

.656.0344.011 pq

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• The standardized test statistic is:

)11

(

)()ˆˆ(

21

2121

nnqp

ppppz

775.1

)2501

2001

)(656.0)(344.0(

)0()38.030.0(

z

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution• The graph shows the

location of the rejection regions and the standardized test statistic. Because z is in the rejection region, you should decide to reject the null hypothesis. You have enough evidence at the 10% level to conclude there is a difference in the proportion of female and the proportion of male Internet users who plan to shop online.

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Ex. 2: Two-Sample z-Test for the Difference Between Proportions

• A medical research team conducted a study to test the effect of a cholesterol-reducing medication. At the end of the study, the researchers found that of the 4700 subjects who took the medication, 301 died of heart disease. Of the 4300 subjects who took a placebo, 357 died of heart disease. At = 0.01, can you conclude that the death rate is lower for those who took the medication than for those who took the placebo?

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• You want to determine whether there is a difference in the proportions. So, the null and alternative hypotheses are:

Ho: p1 ≥ p2 and p1 < p2 (claim)

Because the test is left-tailed and the level of significance is = 0.01, the critical value is

-2.33. The rejection region is z < -2.33

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• The weighted estimate of the population proportion is:

21

21

nn

xxp

073.09000

658

43004700

357301

p

• And . Because 4700(0.073), 4700(0.927),

4300(0.073) and 4300)0.927 are at least 5, you can use the two-sample z-test.

.927.0073.011 pq

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution

• The standardized test statistic is:

)11

(

)()ˆˆ(

21

2121

nnqp

ppppz

461.3

)4300

14700

1)(927.0)(073.0(

)0()083.0064.0(

z

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Sta

tist

ics

8.4

Solution• The graph shows the

location of the rejection region and the standardized test statistic. Because z is in the rejection region, you should decide to reject the null hypothesis. At the 1% level, there is enough evidence to conclude that the death rate is lower for those who took the medication than for those who took the placebo.