Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 18 Chi-Square Tests.  2 Distribution Let x 1, x 2,.. x n be a random sample from a normal distribution with  and  2, and let s 2 be the sample.

Similar presentations


Presentation on theme: "Chapter 18 Chi-Square Tests.  2 Distribution Let x 1, x 2,.. x n be a random sample from a normal distribution with  and  2, and let s 2 be the sample."— Presentation transcript:

1 Chapter 18 Chi-Square Tests

2  2 Distribution Let x 1, x 2,.. x n be a random sample from a normal distribution with  and  2, and let s 2 be the sample variance, then the random variable (n-1)s 2 /  2 has  2 distribution with n-1 degrees of freedom. Probability Density Function, with k degrees of freedom, Mean Variance Mode = k-2 (when k  3)

3  2 Distribution fr.academic.ru/pictures/frwiki/67/Chi-square_..

4  2 Distribution Goodness-of-fit Tests Tests of Independence Tests of Homogeneity

5 Multinominal Experiments A Multinomial experiment is a statistical experiment that has the following properties: It consists of n repeated trials (repetitions). Each trial can result in one of k possible outcomes. The trials are independent. The probabilities of the various events remain constant for each trial.

6 Goodness-of-fit Test Observed Frequencies (O i ): Frequencies obtained from the actual performance of an experiment. Goodness-of-fit Test: Test of null hypothesis that the observed frequencies follow certain pattern or theoretical distributions, expressed by the Expected Frequencies (E i ).

7 Goodness-of-fit Test for Multinominal Experiments Degree of freedom = k -1, where k is the number of categories Chi-square goodness-of-fit test is always a right-tailed test Sample size should be large enough so that the expected frequency for each category is at least 5.

8 Goodness-of-fit Test for Multinominal Experiments Alt. HypothesisP-valueRejection Criterion H1H1 P(  2 >  0 2 )  0 2 >  2 ,k-1 Null Hypothesis: H 0 : the observed frequencies follow certain pattern Test statistic: Degree of Freedom = k -1

9 Goodness-of-fit Test for Multinominal Experiments -- Example 18.1 Department stores in shopping mall H 0 : p 1 = p 2 = p 3 = p 4 = p 5 =.20 H 1 : At least 2 of p i .20  =.01, df = 5 -1 = 4 Test statistic: Critical value: .01,4 = 13.276 P-value =.000549 Reject H 0 OiOi EiEi O i -E i (O i -E i ) 2 (O i -E i ) 2 /E i 1214200141960.98 2231200319614.81 3182200-183241.62 4219200193611.81 5154200-46211610.58 19.79

10 Goodness-of-fit Test for Multinominal Experiments -- Example 18.2 Market shares H 0 : p 1 =.144, p 2 =.181, p 3 =.248, p 4 =.141, p 5 =.149, p 6 =.137 H 1 : At least 2 of p i are different  =.025, df = 6 -1 = 5 Test statistic: Critical value: .025,5 = 12.8325 P-value =.1252 Fail to reject H 0 OiOi EiEi O i -E i (O i -E i ) 2 (O i -E i ) 2 /E i 1270288-183241.1250 2382362204001.1050 3467496-298411.6956 43172823512254.3440 5288298-101000.3356 6276274240.0146 20008.6197

11 Test of Independence for a Contingency Table Contingency Table Columns 12…c Rows1O 11 O 12 …O 1c u1u1 2O 21 O 22 …O 2c u2u2 ……………… rO r1 O r2 …O rc urur 1 2 c

12 Alt. HypothesisP-valueRejection Criterion H1H1 P(  2 >  0 2 )  0 2 >  2 ,df Null Hypothesis: H 0 : The two attributes are independent Alt. Hypothesis: H 1 : The two attributes are dependent Test statistic: Degree of Freedom = (r-1)(c-1) Test of Independence for a Contingency Table

13 Test of Independence for a Contingency Table – Example 18.3 Contingency Table O ij SupportAgainstNo OpinionTotaluiui Female87326125.4167 Male937012175.5833 Total18010218300 j.60.34.06 E ij SupportAgainstNo Opinion Female7542.57.5 Male10559.510.5

14 Null Hypothesis: H 0 : The two attributes are independent Alt. Hypothesis: H 1 : The two attributes are dependent Test statistic: Degree of Freedom = (r-1)(c-1) = (2-1)(3-1) = 2 Critical value: .025,2 = 7.3778 P-value =.0161 Reject H 0 Test of Independence for a Contingency Table – Example 18.4

15 Test of Independence for a Contingency Table – Example 18.5 Contingency Table O ij GoodDefectiveTotaluiui Mac 110911120.6 Mac 2661480.4 Total17525200 j.875.125 E ij GoodDefective Mac 110515 Mac 27010

16 Null Hypothesis: H 0 : The two attributes are independent Alt. Hypothesis: H 1 : The two attributes are dependent Test statistic: Degree of Freedom = (r-1)(c-1) = (2-1)(2-1) = 1 Critical value: .01,1 = 6.6349 P-value =.0809 Fail to reject H 0 Test of Independence for a Contingency Table – Example 18.5

17 Test of Homogeneity Similar to the test of independence If row/column totals are fixed, perform a test of homogeneity Columns 12…c Rows1O 11 O 12 …O 1c u1u1 2O 21 O 22 …O 2c u2u2 ……………… rO r1 O r2 …O rc urur 1 2 c

18 Alt. HypothesisP-valueRejection Criterion H1H1 P(  2 >  0 2 )  0 2 >  2 ,df Null Hypothesis: H 0 : two sets of data are homogeneous Alt. Hypothesis: H 1 : sets of data are not homogeneous Test statistic: Degree of Freedom = (r-1)(c-1) Test of Homogeneity

19 Test of Independence for a Contingency Table – Example 18.6 Contingency Table O ij Calif.NYTotaluiui Very Satis.6075135.15 Somewhat Sat.100125225.25 Somewhat Dissat.184140324.36 Very Dissatis.15660216.24 Total500400900 j.556.444 E ij Calif.NY Very Satis. 7560 Somewhat Sat. 125100 Somewhat Dissat. 180144 Very Dissatis. 12096

20 Null Hypothesis: H 0 : The two states are homogeneous Alt. Hypothesis: H 1 : The two states are not homogeneous Test statistic: Degree of Freedom = (r-1)(c-1) = (4-1)(2-1) = 3 Critical value: .025,3 = 9.3484 P-value = 3.1424E-9 Reject H 0 Test of Independence for a Contingency Table – Example 18.6


Download ppt "Chapter 18 Chi-Square Tests.  2 Distribution Let x 1, x 2,.. x n be a random sample from a normal distribution with  and  2, and let s 2 be the sample."

Similar presentations


Ads by Google