Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chi Square Test of Homogeneity. Are the different types of M&M’s distributed the same across the different colors? PlainPeanutPeanut Butter Crispy Brown7447.

Similar presentations


Presentation on theme: "Chi Square Test of Homogeneity. Are the different types of M&M’s distributed the same across the different colors? PlainPeanutPeanut Butter Crispy Brown7447."— Presentation transcript:

1 Chi Square Test of Homogeneity

2 Are the different types of M&M’s distributed the same across the different colors? PlainPeanutPeanut Butter Crispy Brown7447 Blue21448 Yellow4414 Red4187 Green3667 Total39192333

3 1. An overall test to see if there is good evidence of any difference among the parameters that we want to compare. 2. A detailed follow-up analysis to decide which of the parameters differ and to estimate how large the differences are.

4 H o : There is no difference in the distribution of a categorical variable for several populations or treatments H a : There is a difference in the distribution of a categorical variable for several populations or treatments. We compare the observed counts in a two-way table with the counts we would expect if H o were true.

5

6 The chi-square statistic is a measure of how far the observed counts in a two-way table are from the expected counts. The formula for the statistic is  2 = The sum is over all row x column cells in the table. #2&3

7 Suppose the conditions are met. You can use the chi-square test for homogeneity to test H 0 : There is no difference in the distribution of a categorical variable for several populations or treatments. H a : There is a difference in the distribution of a categorical variable for several populations or treatments. Start by finding the expected count for each category assuming that H 0 is true. Then calculate the chi-square statistic where the sum is over all cells (not including totals) in the two-way table. If H 0 is true, the  2 statistic has approximately a chi-square distribution with degrees of freedom = (number of rows − 1)(number of columns − 1). The P-value is the area to the right of  2 under the corresponding chi-square density curve.

8  Random: The data come from separate random samples from each population of interest or from groups in a randomized experiment.  Large Sample Size: All expected counts are at least 5  Independent: Both the samples or groups themselves and the individual observations in each sample or group are independent. When sampling without replacement, check that the individual populations are at least 10 times as large as the corresponding samples

9  If the test allows us to reject the null hypothesis of no difference, you then want to do a follow-up analysis that examines the differences in detail  Start by examining which cells in the two-way table show large deviations between the observed and expected counts  Then look at the individual components to see which terms contribute most to the chi- square statistic

10 Run a Chi-Square Test for Homogeneity for the M&M’s. PlainPeanutPeanut Butter Crispy Brown7447 Blue21448 Orange144510 Yellow4414 Red4187 Green3667


Download ppt "Chi Square Test of Homogeneity. Are the different types of M&M’s distributed the same across the different colors? PlainPeanutPeanut Butter Crispy Brown7447."

Similar presentations


Ads by Google