Upload
willa-craft
View
41
Download
0
Tags:
Embed Size (px)
DESCRIPTION
Chapter 11 Comparisons Involving Proportions and A Test of Independence. Chapter Outline. Goodness of Fit test Test of Independence. Goodness of Fit Test. Hypothesis test for proportions of a multinomial population - PowerPoint PPT Presentation
Citation preview
1
Chapter 11
Comparisons Involving Proportions and A Test of Independence
2
Chapter Outline
Goodness of Fit testTest of Independence
3
Goodness of Fit Test
Hypothesis test for proportions of a multinomial populationHypothesis test for proportions of a multinomial population It compares the observed and expected frequencies in each It compares the observed and expected frequencies in each
category to test either that all categories contain the same category to test either that all categories contain the same proportion of values or that each category contains a user-proportion of values or that each category contains a user-specified proportion of values.specified proportion of values.
4
Goodness of Fit Test
ProcedureProcedure1.1. Set up the null and alternative hypotheses;Set up the null and alternative hypotheses;
2.2. Select a random sample and record the Select a random sample and record the observed frequency, observed frequency, ffii, for each of the , for each of the kk
categories;categories;
3.3. Assuming Assuming HH00 is true, compute the expected is true, compute the expected
frequency, frequency, eeii, in each category by multiplying , in each category by multiplying
the category probability by the sample size.the category probability by the sample size.
5
Goodness of Fit Test
ProcedureProcedure4. Compute the value of the test statistic:4. Compute the value of the test statistic:
22
1
( )f ee
i i
ii
k2
2
1
( )f ee
i i
ii
k
ffii = observed frequency for category = observed frequency for category iieeii = expected frequency for category = expected frequency for category ii
kk = number of categories = number of categories
where:where:
Note: The test statistic has a chi-square distribution with Note: The test statistic has a chi-square distribution with kk – 1 – 1 degrees of freedom provided that the expected frequencies are 5 degrees of freedom provided that the expected frequencies are 5 or more for all categories.or more for all categories.
6
Goodness of Fit Test
ProcedureProcedure5. Rejection rule:5. Rejection rule:
where where is the significance level and is the significance level andthere are there are kk - 1 degrees of freedom - 1 degrees of freedom
pp-value approach:-value approach:
Critical value approach:Critical value approach:
Reject Reject HH00 if if pp-value -value <<
2 2 2 2 Reject Reject HH00 if if
7
Goodness of Fit Test
Example: Market ShareExample: Market Share In the Scott Market Research example in the textbook, In the Scott Market Research example in the textbook,
after company C introduced a new product to the market, a after company C introduced a new product to the market, a survey was conducted on 200 customers to study if there is survey was conducted on 200 customers to study if there is any change in the market shares. Out of the 200 any change in the market shares. Out of the 200 customers, 48 prefer company A’s product, 98 prefer customers, 48 prefer company A’s product, 98 prefer company B’s, and 54 prefer company’s C’s. Before the company B’s, and 54 prefer company’s C’s. Before the introduction of the new product by company C, the market introduction of the new product by company C, the market shares of the three companies were:shares of the three companies were:
2.0,5.0,3.0 CBA ppp
8
Goodness of Fit Test
Example: Market ShareExample: Market Share HypothesesHypotheses
HH00: : ppAA = .3; = .3; ppBB = .5; = .5; ppCC = .2 = .2
HHaa: The population proportions are not : The population proportions are not
ppAA = .3; = .3; ppBB = .5; = .5; ppCC = .2 = .2
where:where:
ppAA = the population market share of company A; = the population market share of company A;
ppBB = the population market share of company B; = the population market share of company B;
ppCC = the population market share of company C. = the population market share of company C.
9
Goodness of Fit Test
Example: Market ShareExample: Market Share Rejection ruleRejection rule
Reject H0 if if pp-value -value << .05 or .05 or 22 >> 5.99. 5.99.
22
5.99 5.99
Do Not Reject H0Do Not Reject H0 Reject H0Reject H0
With With = .05 and = .05 and
kk - 1 = 3 - 1 = 2 - 1 = 3 - 1 = 2
degrees of freedomdegrees of freedom
10
Goodness of Fit Test Example: Market ShareExample: Market Share
Expected FrequenciesExpected Frequencies
Observed FrequenciesObserved Frequencies
Test StatisticTest Statistic
eA=.3(200)=60; eB=.5(200)=100; eC=.2(200)=40
fA = 48; fB = 98; fC = 54
= 2.4+0.04+4.9 = 7.34
40
4054
100
10098
60
6048 2222
11
Goodness of Fit Test
Example: Market ShareExample: Market Share pp-Value Approach-Value Approach
Area in Upper Tail .10 .05 .025 .01 .005Area in Upper Tail .10 .05 .025 .01 .005
22 Value (df = 2) 4.6 5.99 7.38 9.21 10.60 Value (df = 2) 4.6 5.99 7.38 9.21 10.60
The The pp-value -value << = .05. We can reject the null hypothesis. = .05. We can reject the null hypothesis.
Because Because 22 = 7.34 is between 5.99 and 7.38, the area in the = 7.34 is between 5.99 and 7.38, the area in the upper tail of the distribution is between .05 and .025.upper tail of the distribution is between .05 and .025.
12
Goodness of Fit Test
Example: Market ShareExample: Market Share CriticalCritical Value ApproachValue Approach
2 2 = = 7.34 7.34 >> 5.99 5.99
We reject, at the .05 level of significance,We reject, at the .05 level of significance,
the assumption that the market shares of companiesthe assumption that the market shares of companies
A, B, and C remain the same after Company C A, B, and C remain the same after Company C
introduced a new product.introduced a new product.
13
Test of Independence: Contingency Tables
Hypothesis test for independence between two Hypothesis test for independence between two variables.variables.
Similar to a Goodness of Fit test, it computes Similar to a Goodness of Fit test, it computes 22 test statistic based on the observed frequencies and test statistic based on the observed frequencies and expected frequencies (assuming the null expected frequencies (assuming the null hypothesis is true, i.e. the two variables are hypothesis is true, i.e. the two variables are independent from each other). independent from each other).
14
Test of Independence
ProcedureProcedure1.1. Set up the null and alternative hypotheses;Set up the null and alternative hypotheses;
2.2. Select a random sample and record the Select a random sample and record the observed frequency, observed frequency, ffijij, for each cell of the , for each cell of the
contingency table;contingency table;
3.3. Assuming Assuming HH00 is true, compute the expected is true, compute the expected
frequency, frequency, eeijij, for each cell as follows:, for each cell as follows:
ei j
ij (Row Total )(Column Total ) Sample Size
ei j
ij (Row Total )(Column Total ) Sample Size
15
Test of Independence
ProcedureProcedure4.4. Compute the test statisticCompute the test statistic
5.5. Determine the rejection ruleDetermine the rejection rule
22
( )f e
eij ij
ijji2
2
( )f e
eij ij
ijji
Reject Reject HH00 if if p p -value-value << oror . .
2 2 2 2
where where is the significance level and, is the significance level and,with with nn rows and rows and mm columns, there are columns, there are((nn - 1)( - 1)(mm - 1) degrees of freedom. - 1) degrees of freedom.
16
Test of Independence Example: Field of StudyExample: Field of Study
The following table shows the results of recent study The following table shows the results of recent study regarding gender of individuals and their selected field of regarding gender of individuals and their selected field of study.study.
Field of Study
Medicine Business Engineering Total
Male 80 60 160 300
Female 40 20 40 100
Total 120 80 200 400
17
Test of Independence Example: Field of StudyExample: Field of Study
HypothesisHypothesis
HH00: Field of study : Field of study is independentis independent of gender of gender
HHaa: Field of study : Field of study is not independentis not independent of gender of gender
18
Test of Independence Example: Field of StudyExample: Field of Study
Expected FrequenciesExpected Frequencies
Field of Study
Medicine Business Engineering Total
Male 300*120/400=90
300*80/400
=60
300*200/400=150
300
Female 100*120/400=30
100*80/400
=20
100*200/400=50
100
Total 120 80 200 400
19
Test of Independence Example: Field of StudyExample: Field of Study
Rejection RuleRejection Rule Reject H0 if if pp-value -value << =.05 =.05
or or 22 >> 5.99 [d.f. = (2-1)(3-1)=2]. 5.99 [d.f. = (2-1)(3-1)=2].
Test StatisticTest Statistic
50
5040
60
6060
90
9080 2222
= 1.11 + 0 + . . . + 2 = 7.11= 1.11 + 0 + . . . + 2 = 7.11
20
Test of Independence
Example: Field of StudyExample: Field of Study pp-Value Approach-Value Approach
Area in Upper Tail .10 .05 .025 .01 .005Area in Upper Tail .10 .05 .025 .01 .005
22 Value (df = 2) 4.6 5.99 7.38 9.21 10.60 Value (df = 2) 4.6 5.99 7.38 9.21 10.60
The The pp-value -value << = .05. We can reject the null hypothesis. = .05. We can reject the null hypothesis.
Because Because 22 = 7.11 is between 5.99 and 7.38, the area in the = 7.11 is between 5.99 and 7.38, the area in the upper tail of the distribution is between .05 and .025.upper tail of the distribution is between .05 and .025.
21
Test of Independence
Example: Field of StudyExample: Field of Study CriticalCritical Value ApproachValue Approach
2 2 = = 7.11 7.11 >> 5.99 5.99
We reject, at the .05 level of significance,We reject, at the .05 level of significance,
the null hypothesis that the selected field of study the null hypothesis that the selected field of study
is independent of gender.is independent of gender.