Presentation is loading. Please wait.

Presentation is loading. Please wait.

Test of Homogeneity Lecture 45 Section 14.4 Tue, Apr 12, 2005.

Similar presentations


Presentation on theme: "Test of Homogeneity Lecture 45 Section 14.4 Tue, Apr 12, 2005."— Presentation transcript:

1 Test of Homogeneity Lecture 45 Section 14.4 Tue, Apr 12, 2005

2 Homogeneous Populations Two distributions are called homogeneous if they exhibit the same proportions within categories. Two distributions are called homogeneous if they exhibit the same proportions within categories. For example, if two colleges’ student bodies are each 55% female and 45% male, then the distributions are homogeneous. For example, if two colleges’ student bodies are each 55% female and 45% male, then the distributions are homogeneous.

3 Example Suppose a teacher teaches two sections of Statistics and uses two different teaching methods. Suppose a teacher teaches two sections of Statistics and uses two different teaching methods. At the end of the semester, he compares the grade distributions on the final exam. (Both classes had the same final exam.) At the end of the semester, he compares the grade distributions on the final exam. (Both classes had the same final exam.) He wants to know if the differences that he observes are significant. He wants to know if the differences that he observes are significant.

4 Example Does there appear to be a difference? Does there appear to be a difference? Or are the two sets (plausibly) homogeneous? Or are the two sets (plausibly) homogeneous? ABCDF Method I231252 Method II25630

5 The Test of Homogeneity The null hypothesis is that the populations are homogeneous. The null hypothesis is that the populations are homogeneous. The alternative hypothesis is that the populations are not homogeneous. The alternative hypothesis is that the populations are not homogeneous. H 0 : The populations are homogeneous. H 1 : The populations are not homogeneous. Notice that H 0 does not specify a distribution; it just says that whatever the distribution is, it is the same in all rows. Notice that H 0 does not specify a distribution; it just says that whatever the distribution is, it is the same in all rows.

6 The Test Statistic The test statistic is the chi-square statistic, computed as The test statistic is the chi-square statistic, computed as The question now is, how do we compute the expected counts? The question now is, how do we compute the expected counts?

7 Expected Counts Under the assumption of homogeneity (H 0 ), the rows should exhibit the same proportions. Under the assumption of homogeneity (H 0 ), the rows should exhibit the same proportions. We can get the best estimate of those proportions by pooling the rows. We can get the best estimate of those proportions by pooling the rows. That is, add the rows (i.e., find the column totals), and then compute the column proportions from them. That is, add the rows (i.e., find the column totals), and then compute the column proportions from them.

8 Row and Column Proportions ABCDF Method I231252 Method II25630 Col Total481882 10%20%45%20%5%

9 Expected Counts Similarly, the columns should exhibit the same proportions, so we can get the best estimate by pooling the columns. Similarly, the columns should exhibit the same proportions, so we can get the best estimate by pooling the columns. That is, add the columns (i.e., find the row totals), and then compute the row proportions from them. That is, add the columns (i.e., find the row totals), and then compute the row proportions from them.

10 Row and Column Proportions ABCDF Row Total Method I2312522460% Method II256301640% Col Total481882 10%20%45%20%5%

11 Row and Column Proportions ABCDF Row Total Method I2312522460% Method II256301640% Col Total48188240 10%20%45%20%5% Grand Total

12 Expected Counts Now apply the appropriate row and column proportions to each cell to get the expected count. Now apply the appropriate row and column proportions to each cell to get the expected count. Let’s use the upper-left cell as an example. Let’s use the upper-left cell as an example. According to the row and column proportions, it should contain 60% of 10% of the grand total 40. According to the row and column proportions, it should contain 60% of 10% of the grand total 40. That is, the expected count is That is, the expected count is 0.60  0.10  40 = 2.4

13 Expected Counts Notice that this can be obtained more quickly by the following formula. Notice that this can be obtained more quickly by the following formula. In the upper-left cell, this formula produces In the upper-left cell, this formula produces (4  24)/40 = 2.4

14 Expected Counts Apply that formula to each cell to find the expected counts and add them to the table. Apply that formula to each cell to find the expected counts and add them to the table. ABCDF Method I 2 (2.4) 3 (4.8) 12 (10.8) 5 (4.8) 2 (1.2) Method II 2 (1.6) 5 (3.2) 6 (7.2) 3 (3.2) 0 (0.8)

15 The Test Statistic Now compute  2 in the usual way. Now compute  2 in the usual way.

16 Degrees of Freedom The number of degrees of freedom is The number of degrees of freedom is df = (no. of rows – 1)  (no. of cols – 1). In our example, df = (2 – 1)  (5 – 1) = 4. In our example, df = (2 – 1)  (5 – 1) = 4. To find the p-value, calculate To find the p-value, calculate  2 cdf(3.5416667, E99, 4) = 0.47157. Clearly, the differences are not statistically significant. Clearly, the differences are not statistically significant.

17 Let’s Do It! Let’s Do It! 14.4, p. 873 – Preventing Pregnancies. Let’s Do It! 14.4, p. 873 – Preventing Pregnancies. Compute the first cell’s contribution to  2. Compute the first cell’s contribution to  2. Do (a), (b), and (c). Do (a), (b), and (c).

18 TI-83 – Test of Homogeneity The tables in these examples are not lists, so we can’t use the lists in the TI-83. The tables in these examples are not lists, so we can’t use the lists in the TI-83. Instead, the tables are matrices. Instead, the tables are matrices. Happily, the TI-83 can handle matrices. Happily, the TI-83 can handle matrices.

19 TI-83 – Test of Homogeneity Enter the observed counts into a matrix. Enter the observed counts into a matrix. Press MATRIX. Press MATRIX. Select EDIT. Select EDIT. Press ENTER to edit matrix [A]. Press ENTER to edit matrix [A]. Enter the number of rows and columns. (Press ENTER to advance.) Enter the number of rows and columns. (Press ENTER to advance.) Enter the observed counts in the cells. Enter the observed counts in the cells. Press 2 nd Quit to exit the matrix editor. Press 2 nd Quit to exit the matrix editor.

20 TI-83 – Test of Homogeneity Perform the test of homogeneity. Perform the test of homogeneity. Select STATS > TESTS >  2 -Test… Select STATS > TESTS >  2 -Test… Press ENTER. Press ENTER. Enter the matrix of observed counts. Enter the matrix of observed counts. Enter the name ([E]) of a matrix for the expected counts. These will be computed for you by the TI- 83. Enter the name ([E]) of a matrix for the expected counts. These will be computed for you by the TI- 83. Select Calculate. Select Calculate. Press ENTER. Press ENTER.

21 TI-83 – Test of Homogeneity The window displays The window displays The title “  2 -Test”. The title “  2 -Test”. The value of  2. The value of  2. The p-value. The p-value. The number of degrees of freedom. The number of degrees of freedom. See the matrix of expected counts. See the matrix of expected counts. Press MATRIX. Press MATRIX. Select matrix [E]. Select matrix [E]. Press ENTER. Press ENTER.

22 Example Let’s do “Let’s Do It!” 14.4, p. 873, on the TI- 83. Let’s do “Let’s Do It!” 14.4, p. 873, on the TI- 83. Enter the matrix Enter the matrix Perform the test  2 -Test. Perform the test  2 -Test. Compare the results to the Minitab display on page 873. Compare the results to the Minitab display on page 873. 51216 958884


Download ppt "Test of Homogeneity Lecture 45 Section 14.4 Tue, Apr 12, 2005."

Similar presentations


Ads by Google