{"id":386,"date":"2020-04-10T08:08:25","date_gmt":"2020-04-10T12:08:25","guid":{"rendered":"http:\/\/pressbooks.library.upei.ca\/montelpare\/?post_type=chapter&#038;p=386"},"modified":"2020-08-24T14:16:26","modified_gmt":"2020-08-24T18:16:26","slug":"the-goodness-of-fit-test-for-two-groups","status":"publish","type":"chapter","link":"https:\/\/pressbooks.library.upei.ca\/montelpare\/chapter\/the-goodness-of-fit-test-for-two-groups\/","title":{"raw":"The Goodness of Fit Test for Two Groups","rendered":"The Goodness of Fit Test for Two Groups"},"content":{"raw":"<h1>The Two-Sample Chi-Square Goodness of Fit Test<\/h1>\r\nIn this chapter, we will work through examples of the Goodness of Fit chi-square when we have two groups. Here we will use both SAS coding as well as the two sample webulator for a goodness of fit test. The two sample webulator enables us to compare the distribution of responses for one sample against the distribution of the responses for a second sample.\r\n\r\nIn the following example, we applied the goodness of fit test for a sample of individuals that were asked about their health status.\u00a0 The tool to collect the information was the RAND SF-36. In this example, we also added demographic information to represent sex, and although the response categories for SEX were (1=male, 2=female and 3=other)\u00a0 we processed the data as a binary outcome (males versus females).\u00a0 The data set was comprised of three variables which included id, sex and the individual\u2019s response to the five-item question: 1. In general, would you say your health is:\u00a0 i)\u00a0 Excellent, ii) \u00a0Very good, iii) \u00a0Good, iv) \u00a0Fair, v)\u00a0 Poor.\r\n<div class=\"textbox textbox--exercises\"><header class=\"textbox__header\">\r\n<p class=\"textbox__title\">The relevant SAS code added to process the 2 group chi-square goodness of fit test<\/p>\r\n\r\n<\/header>\r\n<div class=\"textbox__content\">PROC FORMAT;\r\nVALUE HEAFMT 1 = EXCELLENT 2 = VERY GOOD 3 = GOOD 4 = FAIR 5 = POOR;\r\nVALUE GENFMT 1=MALE 2=FEMALE 3=OTHER;DATA CHIGF2;\r\nINPUT ID SEX HEALTH @@;LABEL HEALTH='OPTIONS FOR RAND SF-36 HEALTH QUESTION';\r\nTITLE 'TWO GROUP GOODNESS OF FIT FOR HEALTH STATUS RAND SF-36 ';DATALINES;\r\n001 1 1 002 1 2 003 1 3 004 1 4 005 1 5 006 2 1\u00a0 007 2 2 008 2 3 009 2 4 010 2 5 011 3 1 012 1 2\u00a0013 3 3 014 1 4 015 1 5 016 2 1 017 2 2 018 2 3\u00a0019 2 4 020 2 5 021 1 1 022 1 2 023 1 3 024 1 4\u00a0025 1 5 026 2 1 027 2 2 028 2 3 029 2 4 030 2 5 041 1 1 042 1 1 043 1 1 044 1 1 045 3 1 046 2 1\u00a0047 2 1 048 2 1 049 2 1 050 3 1 031 1 5 032 1 5\u00a0033 1 5 034 3 5 035 1 5 036 2 5 037 3 5 038 3 5\u00a0039 2 5 040 2 5 101 1 1 102 1 2 103 1 3 104 1 4\u00a0105 1 5 106 2 1 107 2 2 108 2 3 109 2 4 060 3 5\u00a0061 3 1 062 1 2 063 1 3 064 1 4 065 1 5 066 2 1\u00a0067 3 2 068 2 3 609 2 4 700 3 5 081 1 1 082 3 2\u00a0083 1 3 084 1 4 085 1 5 086 3 1 087 2 2 088 2 3\u00a0089 2 4 090 2 5 081 1 1 082 1 1 083 1 1 084 1 1\u00a0085 1 1 086 2 1 087 2 1 088 2 1 089 2 1 080 2 1\u00a0051 3 5 052 3 5 053 1 5 054 1 5 055 1 5 056 2 5\u00a0057 3 5 058 3 5 059 2 5 100 2 5 160 2 5 161 3 1\u00a0162 1 2 613 1 3 641 1 4 651 1 5 166 2 1 167 3 2\u00a0168 2 3 169 2 4 170 2 5 181 1 1 182 1 2 183 3 3\u00a0184 1 4 185 3 5 186 2 1 187 2 2 188 2 3 189 3 4 190 2 5 181 3 1 182 1 1 288 3 1 289 2 1 280 2 1\u00a0251 1 4 252 1 3 253 1 4 254 3 3 255 1 4 256 2 3\u00a0257 2 4 258 2 4 259 2 3 100 2 2 160 2 5 161 1 1\u00a0 162 1 2 613 1 3 641 1 4 651 1 5 166 2 1 167 2 2\u00a0988 2 1 389 2 3 380 2 1 351 3 5 352 1 5 353 1 5\u00a0 354 1 5 355 1 5 356 2 5 357 3 5 358 2 5 359 2 5\u00a0100 2 5 160 2 5 161 1 1 162 3 2 613 1 3 641 1 4 651 1 5 166 2 1 167 2 2 560 2 5 561 1 1 562 1 2\u00a0 563 1 3 564 1 4 565 1 5 566 2 1 567 2 2 568 2 3\u00a0569 2 4 570 2 5 581 1 1 582 1 2 583 1 3 584 3 4\u00a0585 1 5 586 2 1 587 2 2 588 2 3 589 2 4 590 3 5\u00a0581 1 1 582 1 2 583 1 2 584 1 2 585 1 2 586 3 2\u00a0587 2 1 588 2 1 589 2 3 580 3 3 551 1 3 552 1 5\u00a0 553 1 4 554 1 5 555 1 4 556 3 5 557 2 4 558 2 4\u00a0559 3 3\r\n;\r\n\/* PRODUCE A HISTOGRAM FOR THE ENTIRE SET OF DATA*\/PROC SORT DATA=CHIGF2; BY SEX;\r\nPROC SGPLOT; HISTOGRAM HEALTH;\r\nFORMAT HEALTH HEAFMT. ;\r\nRUN;\/* CALCULATE CHI SQUARE GOODNESS OF FIT - MALES VS FEMALES *\/PROC FREQ;\r\nTABLES HEALTH*SEX\/CHISQ;\r\nWHERE SEX&lt;3; \/* RESTRICT DATA TO A TWO GROUP COMPARISON *\/\r\nFORMAT HEALTH HEAFMT. SEX SEXFMT. ;\r\nTITLE 'FREQUENCY DISTRIBUTION FOR SELF-REPORTED HEALTH STATUS';\r\nTITLE2 'TWO SAMPLE GOODNESS OF FIT STUDY';\r\nRUN;\/*CREATE A GRAPH USING COLORS *\/\r\n\/* Define the axis characteristics *\/\r\naxis1 offset=(0,70) minor=none;\r\naxis2 label=(angle=90);\r\npattern1 value=solid color=cx7c95ca;\r\npattern2 value=solid color=cxde7e6f;proc sort; by SEX;\r\nproc gchart ;\r\nvbar HEALTH \/ SUBGROUP=SEX TYPE=PERCENT\r\ndiscrete raxis=axis2;\r\nWHERE SEX&lt;3; \/* RESTRICT DATA TO A TWO GROUP COMPARISON *\/\r\nFORMAT HEALTH HEAFMT. SEX GENFMT. ;\r\n\/* Define the title *\/\r\nTITLE 'FREQUENCY DISTRIBUTION FOR SELF-REPORTED HEALTH STATUS';\r\nTITLE2 'TWO SAMPLE GOODNESS OF FIT STUDY';\r\nrun;\r\nproc sort; by SEX; RUN;\/* ENDS SAS PROCESSING *\/<\/div>\r\n<\/div>\r\nBy separating the data by sex we can compare the distributions for males against the distributions for females.\r\n\r\nWhereas the SGPLOT procedure produces a histogram for the entire set of data, notice the proc gchart procedure produces a vertical bar chart to compare the percent responses for males versus females. The data for the graphs are compared statistically using PROC FREQ with the Chi-square option; the results follow in the table below the graphs.\r\n\r\n<img src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare.png\" alt=\"\" class=\"aligncenter size-full wp-image-1676\" width=\"800\" height=\"600\" \/>\r\n\r\n&nbsp;\r\n\r\nThe statistical analysis that compares the distribution for the three groups of participants is shown in the following frequency distribution table.\r\n<p style=\"text-align: center\">Table 17.1 Frequency Distribution Table<\/p>\r\n\r\n<article id=\"IDX2\" aria-label=\"Chi-Square Tests\">\r\n<table class=\"lines aligncenter\" style=\"height: 105px\" aria-label=\"Chi-Square Tests\"><caption aria-label=\"Chi-Square Tests\">Statistics for Table of HEALTH by SEX<\/caption><colgroup> <col \/><\/colgroup> <colgroup> <col \/> <col \/> <col \/><\/colgroup>\r\n<thead>\r\n<tr style=\"height: 15px\">\r\n<th class=\"b header\" style=\"height: 15px;width: 371px\" scope=\"col\">Statistic<\/th>\r\n<th class=\"r b header\" style=\"height: 15px;width: 46px;vertical-align: middle\" scope=\"col\">DF<\/th>\r\n<th class=\"r b header\" style=\"height: 15px;width: 87px;vertical-align: middle\" scope=\"col\">Value<\/th>\r\n<th class=\"r b header\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">Prob<\/th>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Chi-Square<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">4<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\"><span style=\"background-color: #ffff00\">1.8010<\/span><\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><span style=\"background-color: #ffff00\">0.7723<\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Likelihood Ratio Chi-Square<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">4<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">1.8049<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">0.7716<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Mantel-Haenszel Chi-Square<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">1<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.7697<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">0.3803<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Phi Coefficient<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1026<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Contingency Coefficient<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1021<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Cramer's V<\/th>\r\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1026<\/td>\r\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\r\n<\/tr>\r\n<\/thead>\r\n<\/table>\r\n<\/article>\r\n<div class=\"proc_note_group\">\r\n<p class=\"c proctitle\" style=\"text-align: center\">Sample Size = 171<\/p>\r\n\r\n<\/div>\r\nThese data suggest that there is no difference in the distributions for males versus females for the responses to the health status question ( = 1.80 p=0.77). The chi-square output is highlighted in the summary table, above.\r\n\r\nThe SAS output produces a frequency distribution table that presents the data separately for males and females. There is no data for subjects that declared other in this example because we restricted the SAS processing of the data with the command WHERE SEX&lt;3;\r\n<p style=\"text-align: center\"><strong>Table 17.2 Frequency Distribution for Health by Sex<\/strong><\/p>\r\n\r\n<table class=\"lines aligncenter\" style=\"width: 523px;height: 90px\">\r\n<tbody>\r\n<tr style=\"height: 15px\">\r\n<th style=\"width: 329.317px;height: 15px\"><\/th>\r\n<td style=\"width: 142.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>Males<\/div>\r\n<\/div><\/td>\r\n<td style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>Females<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">EXCELLENT<\/th>\r\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>20<\/div>\r\n<\/div><\/td>\r\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>26<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">VERY GOOD<\/th>\r\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>14<\/div>\r\n<\/div><\/td>\r\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>11<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">GOOD<\/th>\r\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>12<\/div>\r\n<\/div><\/td>\r\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>14<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">FAIR<\/th>\r\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>16<\/div>\r\n<\/div><\/td>\r\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>13<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">POOR<\/th>\r\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>24<\/div>\r\n<\/div><\/td>\r\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\r\n<div class=\"stacked-cell\">\r\n<div>21<\/div>\r\n<\/div><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\nThese data can also be evaluated using the two-sample chi-square Webulator, for an ordinal scaled problem with 5 outcomes as shown below:\r\n\r\nhttps:\/\/health.ahs.upei.ca\/webulators\/fiveby2.html\r\n\r\n<code>[h5p id=\"14\"]<\/code>\r\n<h3>AN ANNOTATED EXAMPLE: Chi-Square Goodness of Fit Test For Two Samples<\/h3>\r\nThe following is an example of the two-group chi-square based on a study of the distribution of cell phone use by individuals relative to motor vehicle collisions.\r\n\r\nIn 2010, Issar, Kadakia, Tsahakis, Yoneda et al (2013), conducted a study to investigate the link between texting and motor vehicle collisions (MVC).\u00a0 Data were collected using a questionnaire sent to patients attending an orthopaedic trauma clinic. The responses were organized into two groups as follows: Group 1 included patients who were involved in a MVC and were driving the vehicle at the time of the collision, and Group 2 consisted of all other patients attending the orthopedic clinic between October 2010 to March 2011.\r\n\r\nIn Table 17.3 the frequency of general phone use by Group 1 and Group 2 is presented.\u00a0 Although both frequency data (counts) and percentages are reported, we can use a two-group chi-square goodness of fit analysis to evaluate the frequency data.\r\n<p style=\"text-align: center\">Table 17.3 General Phone Use Frequencies for MVC vs. non-MVC Phone use<a href=\"#_ftn1\">[1]<\/a><\/p>\r\n\r\n<table class=\"aligncenter\">\r\n<tbody>\r\n<tr>\r\n<td>Phone use\r\n\r\n(hours\/week)<\/td>\r\n<td>Group 1: MVC<\/td>\r\n<td>Group 2: Non-MVC<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>0 \u2013 1<\/td>\r\n<td>15 (26.3%)<\/td>\r\n<td>32 (26.7%)<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>1 \u2013 2<\/td>\r\n<td>11 (19.3)<\/td>\r\n<td>24 (20.0%)<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>2 \u2013 3<\/td>\r\n<td>10 (17.5%)<\/td>\r\n<td>16 (13.3%)<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>3 \u2013 4<\/td>\r\n<td>6 (10.5%)<\/td>\r\n<td>13 (10.8%)<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>&gt;4<\/td>\r\n<td>15 (26.3%)<\/td>\r\n<td>35 (29.2%)<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\nThe data from Table 17.3 are used to determine if the two groups differ in their phone use, measured in hours per week. In order to ensure that the research is not biased, the null hypothesis will be: \"there is no association between MVC group and cell phone use in hours per week\". Our first step in the evaluation process is to state the expected response pattern. The expected response pattern is consistent with our \u201cexpected distribution\u201d. In other words, in an unbiased research study, we should expect that all possible responses are equally as likely to occur within each of the samples. In the examples presented here, twenty percent of each group should answer each of the response options. We call this the unbiased null hypothesis and state it in terms of frequencies of responses. The null hypothesis for this set of examples is\r\n<p style=\"text-align: center\">H0: frequency response in Group<sub>11...5<\/sub> = frequency response in Group<sub>21...5<\/sub><\/p>\r\nThe data responses for this example are presented in Table 17.4 below.\u00a0 The arrangement of these data forms a 2 x 5 contingency table and therefore is analyzed using the standard chi-square formula.\r\n<div>\r\n\r\n<img src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/chisquFRM.png\" alt=\"\" width=\"181\" height=\"104\" class=\"aligncenter size-full wp-image-432\" \/>\r\n\r\n<\/div>\r\n<div>\r\n<p style=\"text-align: center\"><strong>T<span style=\"font-size: 1em\">able 17.4 Raw Data Used in the 2 x 5 Chi-Square Analysis<\/span><\/strong><\/p>\r\n\r\n<\/div>\r\n<table class=\"aligncenter\" style=\"width: 305px\">\r\n<tfoot>\r\n<tr class=\"shaded\">\r\n<td style=\"width: 119.85px;text-align: center\"><strong><em>Column Sums = <\/em><\/strong><\/td>\r\n<td style=\"width: 71.05px;vertical-align: middle;text-align: center\" scope=\"col\"><strong>57<\/strong><\/td>\r\n<td style=\"width: 75.05px;vertical-align: middle;text-align: center\" scope=\"col\"><strong>10<\/strong><\/td>\r\n<\/tr>\r\n<\/tfoot>\r\n<tbody>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>\u00a0<\/em><\/td>\r\n<th class=\"shaded\" style=\"width: 70.25px;text-align: center;vertical-align: middle\" scope=\"col\">MVC Group 1<\/th>\r\n<th class=\"shaded\" style=\"width: 74.25px;text-align: center;vertical-align: middle\" scope=\"col\">Non-MVC Group 2<\/th>\r\n<\/tr>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>Option 1<\/em><\/td>\r\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">15<\/td>\r\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">32<\/td>\r\n<\/tr>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>Option 2<\/em><\/td>\r\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">11<\/td>\r\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">24<\/td>\r\n<\/tr>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>Option 3<\/em><\/td>\r\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">10<\/td>\r\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">16<\/td>\r\n<\/tr>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>Option 4<\/em><\/td>\r\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">6<\/td>\r\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">13<\/td>\r\n<\/tr>\r\n<tr>\r\n<td style=\"width: 119.85px\"><em>Option 5<\/em><\/td>\r\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">15<\/td>\r\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">35<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\nThe chi-square test measures how closely the responses in two distributions match.\u00a0 That is, to what extent is the distribution for MVC Group 1 the same as the Non-MVC Group 2. Enter the frequency data for each option from the datasheet in Table 17.4\u00a0 into the corresponding fields of the webulator below. Click through the frames to compute the 2 x 5 chi-square calculations.\r\n\r\n<code>[h5p id=\"14\"]<\/code>\r\n<div><\/div>\r\nUsing the webulator for the 2 x 5 chi-sqaure we use a stepwise approach to compute the expected values for each cell using the formula\u00a0 (row sum * column sum) \u00f7 grand total.\u00a0 These values are provided in the webulator and shown in the following table.\r\n<p style=\"text-align: center\"><span style=\"text-align: initial;font-size: 1em\"><strong>Table 17.5 Expected values for each cell based on the formula (row sum * column sum) \u00f7 grand total.<\/strong>\u00a0<\/span><\/p>\r\n\r\n<div>\r\n<table class=\"aligncenter\" style=\"border-collapse: collapse;width: 57.8329%;height: 90px\" border=\"0\">\r\n<tbody>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Expected Cell Values<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">MVC Group 1<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">Non-MVC Group 2<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Option 1<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">0.002<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">0.0006<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Option 2<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">0.0065<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">0.003<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Option 3<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">0.31<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">0.15<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Option 4<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">0.002<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">0.001<\/td>\r\n<\/tr>\r\n<tr style=\"height: 15px\">\r\n<td style=\"width: 21.6545%;height: 15px\">Option 5<\/td>\r\n<td style=\"width: 20.6493%;height: 15px\">0.075<\/td>\r\n<td style=\"width: 13.1616%;height: 15px\">0.035<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<\/div>\r\nThe chi-square score also referred to as the chi-square observed is produced in the final frame of the webulator. After computing the chi-square observed value, we next determine the chi-square critical score from a table of chi-square values. The chi-square critical score presented in these examples represents what we should expect to observe for two sample distributions each with five possible responses. The critical value is determined by computing the \u201cdegrees of freedom\u201d for our response set. The computation of the degrees of freedom is:\r\n\r\ndegrees of freedom = (number of rows - 1 ) * (number of columns -1)\r\n[latex]\\therefore [\/latex] degrees of freedom = (5-1) x (2-1)\r\ndegrees of freedom = (4) x (1)\r\ndegrees of freedom = 4\r\n\r\n[latex]\\therefore [\/latex] the <em><strong>chi-square critical value<\/strong><\/em> for (d.f.=4)\u00a0 at p&lt;0.05 = 9.49\r\n\r\nOnce we have calculated the chi-square observed and then determined the chi-square critical then we establish a decision about whether or not to accept or reject the null hypothesis for this comparison. Recall that our null hypothesis was initially set as: the distribution of responses for the MVC Group across the response options would be equal to the distribution of responses for the MVC Group across the response options. Therefore our decision to accept or reject the null hypothesis follows the decision rule: If the \u201cchi-square observed value \u201d is greater than (<strong>\u203a)<\/strong>\u00a0the \u201cchi-square critical value of\u00a0<strong>9.49<\/strong>\u201d, we would reject the null hypothesis and state that the two distributions ARE NOT EQUAL.\u00a0 However, if the \u201cchi-square observed value \u201d is less than (<strong>\u2039)<\/strong>\u00a0the \u201cchi-square critical value of\u00a0<strong>9.49<\/strong>\u201d, we would ACCEPT the null hypothesis and state that the two distributions ARE EQUAL.\r\n\r\nFrom our computations, we can see that the chi-square observed value is<strong> 0.59,<\/strong> which is less than the chi-square critical value of <strong>9.49<\/strong> and therefore we accept the null hypothesis that the two distributions are equal.\u00a0 Restating this outcome with specific reference to texting and MVCs in the Issar study we conclude that the MVC group does not differ from the non-MVC group with respect to their phone hour use per week.\r\n<h4>SAS Code used to verify the two group Chi-Square Goodness of Fit<\/h4>\r\nIn this example, we computed the differences in cell phone use by motor vehicle collisions. The following is the SAS code applied to the computations produced above.\r\n\r\nThe study intended to measure whether the group of individuals that were involved in motor vehicle collisions had the same profile of cell-phone use as the group that were not involved in motor vehicle collisions.\u00a0 The data set was comprised of three variables:\r\n\r\n1) Phone Use:\u00a0 where 1 = '0 to 1 hrs\/wk',\u00a0 2 = '1 to 2 hrs\/wk\u2019, \u00a03 = '2 to 3 hrs\/wk', 4 = '3 to 4 hrs\/wk', 5 = '&gt; 4 hrs\/wk';\u00a0 2) Involvement in a motor vehicle collision: 1 = 'MVC',\u00a0 2 = 'No-MVC';\u00a0 and a third variable which was the number of events reported.\r\n<div class=\"textbox textbox--examples\"><header class=\"textbox__header\">\r\n<p class=\"textbox__title\">The relevant SAS code used to process this two group chi-square goodness of fit is shown here<\/p>\r\n\r\n<\/header>\r\n<div class=\"textbox__content\">\r\n\r\nPROC FORMAT;\r\nVALUE OPTFMT 1 = '0 TO 1 HRS\/WK'\r\n2 = '1 TO 2 HRS\/WK'\r\n3 = '2 TO 3 HRS\/WK'\r\n4 = '3 TO 4 HRS\/WK'\r\n5 = '&gt; 4 HRS\/WK';\r\n\r\nVALUE MVCFMT 1 = 'MVC'\u00a0\u00a0 2 = 'NO-MVC';\r\n\r\nDATA CHIMVC;\r\nTITLE 'PHONE USE AND MOTOR VEHICLE COLLISIONS ';\r\nINPUT PHONEUSE MVC NUM_RPRT @@;\r\n\r\nLABEL PHONEUSE = \"HOURS OF PHONE USE PER WEEK\";\r\nLABEL MVC = \"MOTOR VEHICLE COLLISION\";\r\nLABEL NUM_RPRT = \"NUMBER OF EVENTS REPORTED\";\r\n\r\nDATALINES;\r\n1 1 15 1 2 32 2 1 11 2 2 24 3 1 10 3 2 16 4 1\u00a0 6 4 2 13 5 1 15 5 2 35\r\n;\r\n\r\nPROC SORT; BY\u00a0 MVC;\r\n\/* Define the axis characteristics *\/\r\naxis1 offset=(0,70) minor=none;\r\naxis2 label=(angle=90);\r\npattern1 value=solid color=cx7c95ca;\r\npattern2 value=solid color=cxde7e6f;\r\nPROC GCHART;\r\nBLOCK PHONEUSE \/ SUBGROUP=MVC\r\ndiscrete SUMVAR=NUM_RPRT\r\nCOUTLINE=RED WOUTLINE=1 raxis=axis2;\r\nTITLE1 'BLOCK CHART OF MVC BY PHONE HOURS OF USE';\r\nFORMAT PHONEUSE OPTFMT. MVC MVCFMT. ;\r\n\r\nPROC FREQ; TABLES PHONEUSE*MVC \/ CHISQ ;\r\nWEIGHT NUM_RPRT;\r\nFORMAT PHONEUSE OPTFMT. MVC MVCFMT. ;\r\nTITLE 'COMPARISON OF MVCS BY WEEKLY CELL PHONE USE';\r\n\r\n<\/div>\r\n<\/div>\r\n<p style=\"text-align: center\"><strong>Figure 17.1 Block Chart of the Frequency Distribution for Number of MVCs<\/strong><\/p>\r\n<img src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B.png\" alt=\"\" width=\"588\" height=\"279\" class=\"aligncenter size-full wp-image-1697\" \/>\r\n\r\n<strong>Table 17.6 <\/strong><strong style=\"text-align: initial;font-size: 1em\">Statistics for Table of Phone Use by Motor Vehicle Collision<\/strong>\r\n<div align=\"center\">\r\n<table>\r\n<thead>\r\n<tr>\r\n<td>Statistic<\/td>\r\n<td>DF<\/td>\r\n<td>Value<\/td>\r\n<td>Prob<\/td>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr>\r\n<td>Chi-Square<\/td>\r\n<td>4<\/td>\r\n<td>0.5924<\/td>\r\n<td>0.9639<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>Likelihood Ratio Chi-Square<\/td>\r\n<td>4<\/td>\r\n<td>0.5800<\/td>\r\n<td>0.9653<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>Mantel-Haenszel Chi-Square<\/td>\r\n<td>1<\/td>\r\n<td>0.0327<\/td>\r\n<td>0.8566<\/td>\r\n<\/tr>\r\n<tr>\r\n<td>Phi Coefficient<\/td>\r\n<td><\/td>\r\n<td>0.0579<\/td>\r\n<td><\/td>\r\n<\/tr>\r\n<tr>\r\n<td>Contingency Coefficient<\/td>\r\n<td><\/td>\r\n<td>0.0578<\/td>\r\n<td><\/td>\r\n<\/tr>\r\n<tr>\r\n<td>Cramer's V<\/td>\r\n<td><\/td>\r\n<td>0.0579<\/td>\r\n<td><strong style=\"font-size: 1em\">\u00a0<\/strong><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<\/div>\r\n<div>\r\n<div>\r\n\r\n<a href=\"#_ftnref1\">[1]<\/a> From Issar, Kadakia, Tsahakis, Yoneda et al (2013): The link between texting and motor vehicle collision frequency in the orthopaedic trauma population. J Inj Violence Res. 2013 Jun; 5(2): 95-100.\r\n\r\n<\/div>\r\n<\/div>","rendered":"<h1>The Two-Sample Chi-Square Goodness of Fit Test<\/h1>\n<p>In this chapter, we will work through examples of the Goodness of Fit chi-square when we have two groups. Here we will use both SAS coding as well as the two sample webulator for a goodness of fit test. The two sample webulator enables us to compare the distribution of responses for one sample against the distribution of the responses for a second sample.<\/p>\n<p>In the following example, we applied the goodness of fit test for a sample of individuals that were asked about their health status.\u00a0 The tool to collect the information was the RAND SF-36. In this example, we also added demographic information to represent sex, and although the response categories for SEX were (1=male, 2=female and 3=other)\u00a0 we processed the data as a binary outcome (males versus females).\u00a0 The data set was comprised of three variables which included id, sex and the individual\u2019s response to the five-item question: 1. In general, would you say your health is:\u00a0 i)\u00a0 Excellent, ii) \u00a0Very good, iii) \u00a0Good, iv) \u00a0Fair, v)\u00a0 Poor.<\/p>\n<div class=\"textbox textbox--exercises\">\n<header class=\"textbox__header\">\n<p class=\"textbox__title\">The relevant SAS code added to process the 2 group chi-square goodness of fit test<\/p>\n<\/header>\n<div class=\"textbox__content\">PROC FORMAT;<br \/>\nVALUE HEAFMT 1 = EXCELLENT 2 = VERY GOOD 3 = GOOD 4 = FAIR 5 = POOR;<br \/>\nVALUE GENFMT 1=MALE 2=FEMALE 3=OTHER;DATA CHIGF2;<br \/>\nINPUT ID SEX HEALTH @@;LABEL HEALTH=&#8217;OPTIONS FOR RAND SF-36 HEALTH QUESTION&#8217;;<br \/>\nTITLE &#8216;TWO GROUP GOODNESS OF FIT FOR HEALTH STATUS RAND SF-36 &#8216;;DATALINES;<br \/>\n001 1 1 002 1 2 003 1 3 004 1 4 005 1 5 006 2 1\u00a0 007 2 2 008 2 3 009 2 4 010 2 5 011 3 1 012 1 2\u00a0013 3 3 014 1 4 015 1 5 016 2 1 017 2 2 018 2 3\u00a0019 2 4 020 2 5 021 1 1 022 1 2 023 1 3 024 1 4\u00a0025 1 5 026 2 1 027 2 2 028 2 3 029 2 4 030 2 5 041 1 1 042 1 1 043 1 1 044 1 1 045 3 1 046 2 1\u00a0047 2 1 048 2 1 049 2 1 050 3 1 031 1 5 032 1 5\u00a0033 1 5 034 3 5 035 1 5 036 2 5 037 3 5 038 3 5\u00a0039 2 5 040 2 5 101 1 1 102 1 2 103 1 3 104 1 4\u00a0105 1 5 106 2 1 107 2 2 108 2 3 109 2 4 060 3 5\u00a0061 3 1 062 1 2 063 1 3 064 1 4 065 1 5 066 2 1\u00a0067 3 2 068 2 3 609 2 4 700 3 5 081 1 1 082 3 2\u00a0083 1 3 084 1 4 085 1 5 086 3 1 087 2 2 088 2 3\u00a0089 2 4 090 2 5 081 1 1 082 1 1 083 1 1 084 1 1\u00a0085 1 1 086 2 1 087 2 1 088 2 1 089 2 1 080 2 1\u00a0051 3 5 052 3 5 053 1 5 054 1 5 055 1 5 056 2 5\u00a0057 3 5 058 3 5 059 2 5 100 2 5 160 2 5 161 3 1\u00a0162 1 2 613 1 3 641 1 4 651 1 5 166 2 1 167 3 2\u00a0168 2 3 169 2 4 170 2 5 181 1 1 182 1 2 183 3 3\u00a0184 1 4 185 3 5 186 2 1 187 2 2 188 2 3 189 3 4 190 2 5 181 3 1 182 1 1 288 3 1 289 2 1 280 2 1\u00a0251 1 4 252 1 3 253 1 4 254 3 3 255 1 4 256 2 3\u00a0257 2 4 258 2 4 259 2 3 100 2 2 160 2 5 161 1 1\u00a0 162 1 2 613 1 3 641 1 4 651 1 5 166 2 1 167 2 2\u00a0988 2 1 389 2 3 380 2 1 351 3 5 352 1 5 353 1 5\u00a0 354 1 5 355 1 5 356 2 5 357 3 5 358 2 5 359 2 5\u00a0100 2 5 160 2 5 161 1 1 162 3 2 613 1 3 641 1 4 651 1 5 166 2 1 167 2 2 560 2 5 561 1 1 562 1 2\u00a0 563 1 3 564 1 4 565 1 5 566 2 1 567 2 2 568 2 3\u00a0569 2 4 570 2 5 581 1 1 582 1 2 583 1 3 584 3 4\u00a0585 1 5 586 2 1 587 2 2 588 2 3 589 2 4 590 3 5\u00a0581 1 1 582 1 2 583 1 2 584 1 2 585 1 2 586 3 2\u00a0587 2 1 588 2 1 589 2 3 580 3 3 551 1 3 552 1 5\u00a0 553 1 4 554 1 5 555 1 4 556 3 5 557 2 4 558 2 4\u00a0559 3 3<br \/>\n;<br \/>\n\/* PRODUCE A HISTOGRAM FOR THE ENTIRE SET OF DATA*\/PROC SORT DATA=CHIGF2; BY SEX;<br \/>\nPROC SGPLOT; HISTOGRAM HEALTH;<br \/>\nFORMAT HEALTH HEAFMT. ;<br \/>\nRUN;\/* CALCULATE CHI SQUARE GOODNESS OF FIT &#8211; MALES VS FEMALES *\/PROC FREQ;<br \/>\nTABLES HEALTH*SEX\/CHISQ;<br \/>\nWHERE SEX&lt;3; \/* RESTRICT DATA TO A TWO GROUP COMPARISON *\/<br \/>\nFORMAT HEALTH HEAFMT. SEX SEXFMT. ;<br \/>\nTITLE &#8216;FREQUENCY DISTRIBUTION FOR SELF-REPORTED HEALTH STATUS&#8217;;<br \/>\nTITLE2 &#8216;TWO SAMPLE GOODNESS OF FIT STUDY&#8217;;<br \/>\nRUN;\/*CREATE A GRAPH USING COLORS *\/<br \/>\n\/* Define the axis characteristics *\/<br \/>\naxis1 offset=(0,70) minor=none;<br \/>\naxis2 label=(angle=90);<br \/>\npattern1 value=solid color=cx7c95ca;<br \/>\npattern2 value=solid color=cxde7e6f;proc sort; by SEX;<br \/>\nproc gchart ;<br \/>\nvbar HEALTH \/ SUBGROUP=SEX TYPE=PERCENT<br \/>\ndiscrete raxis=axis2;<br \/>\nWHERE SEX&lt;3; \/* RESTRICT DATA TO A TWO GROUP COMPARISON *\/<br \/>\nFORMAT HEALTH HEAFMT. SEX GENFMT. ;<br \/>\n\/* Define the title *\/<br \/>\nTITLE &#8216;FREQUENCY DISTRIBUTION FOR SELF-REPORTED HEALTH STATUS&#8217;;<br \/>\nTITLE2 &#8216;TWO SAMPLE GOODNESS OF FIT STUDY&#8217;;<br \/>\nrun;<br \/>\nproc sort; by SEX; RUN;\/* ENDS SAS PROCESSING *\/<\/div>\n<\/div>\n<p>By separating the data by sex we can compare the distributions for males against the distributions for females.<\/p>\n<p>Whereas the SGPLOT procedure produces a histogram for the entire set of data, notice the proc gchart procedure produces a vertical bar chart to compare the percent responses for males versus females. The data for the graphs are compared statistically using PROC FREQ with the Chi-square option; the results follow in the table below the graphs.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare.png\" alt=\"\" class=\"aligncenter size-full wp-image-1676\" width=\"800\" height=\"600\" srcset=\"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare.png 800w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare-300x225.png 300w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare-768x576.png 768w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare-65x49.png 65w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare-225x169.png 225w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/twogrpchisquare-350x263.png 350w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>The statistical analysis that compares the distribution for the three groups of participants is shown in the following frequency distribution table.<\/p>\n<p style=\"text-align: center\">Table 17.1 Frequency Distribution Table<\/p>\n<article id=\"IDX2\" aria-label=\"Chi-Square Tests\">\n<table class=\"lines aligncenter\" style=\"height: 105px\" aria-label=\"Chi-Square Tests\">\n<caption aria-label=\"Chi-Square Tests\">Statistics for Table of HEALTH by SEX<\/caption>\n<colgroup>\n<col \/><\/colgroup>\n<colgroup>\n<col \/>\n<col \/>\n<col \/><\/colgroup>\n<thead>\n<tr style=\"height: 15px\">\n<th class=\"b header\" style=\"height: 15px;width: 371px\" scope=\"col\">Statistic<\/th>\n<th class=\"r b header\" style=\"height: 15px;width: 46px;vertical-align: middle\" scope=\"col\">DF<\/th>\n<th class=\"r b header\" style=\"height: 15px;width: 87px;vertical-align: middle\" scope=\"col\">Value<\/th>\n<th class=\"r b header\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">Prob<\/th>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Chi-Square<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">4<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\"><span style=\"background-color: #ffff00\">1.8010<\/span><\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><span style=\"background-color: #ffff00\">0.7723<\/span><\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Likelihood Ratio Chi-Square<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">4<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">1.8049<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">0.7716<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Mantel-Haenszel Chi-Square<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\">1<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.7697<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\">0.3803<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Phi Coefficient<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1026<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Contingency Coefficient<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1021<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"rowheader\" style=\"height: 15px;width: 371px\" scope=\"row\">Cramer&#8217;s V<\/th>\n<td class=\"r data\" style=\"height: 15px;width: 47px;vertical-align: middle\" scope=\"col\"><\/td>\n<td class=\"r data\" style=\"height: 15px;width: 88px;vertical-align: middle\" scope=\"col\">0.1026<\/td>\n<td class=\"r data\" style=\"height: 15px;width: 93px;vertical-align: middle\" scope=\"col\"><\/td>\n<\/tr>\n<\/thead>\n<\/table>\n<\/article>\n<div class=\"proc_note_group\">\n<p class=\"c proctitle\" style=\"text-align: center\">Sample Size = 171<\/p>\n<\/div>\n<p>These data suggest that there is no difference in the distributions for males versus females for the responses to the health status question ( = 1.80 p=0.77). The chi-square output is highlighted in the summary table, above.<\/p>\n<p>The SAS output produces a frequency distribution table that presents the data separately for males and females. There is no data for subjects that declared other in this example because we restricted the SAS processing of the data with the command WHERE SEX&lt;3;<\/p>\n<p style=\"text-align: center\"><strong>Table 17.2 Frequency Distribution for Health by Sex<\/strong><\/p>\n<table class=\"lines aligncenter\" style=\"width: 523px;height: 90px\">\n<tbody>\n<tr style=\"height: 15px\">\n<th style=\"width: 329.317px;height: 15px\"><\/th>\n<td style=\"width: 142.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>Males<\/div>\n<\/div>\n<\/td>\n<td style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>Females<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">EXCELLENT<\/th>\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>20<\/div>\n<\/div>\n<\/td>\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>26<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">VERY GOOD<\/th>\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>14<\/div>\n<\/div>\n<\/td>\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>11<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">GOOD<\/th>\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>12<\/div>\n<\/div>\n<\/td>\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>14<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">FAIR<\/th>\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>16<\/div>\n<\/div>\n<\/td>\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>13<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<th class=\"t rowheader\" style=\"width: 329.317px;height: 15px\" scope=\"row\">POOR<\/th>\n<td class=\"r t data\" style=\"width: 143.15px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>24<\/div>\n<\/div>\n<\/td>\n<td class=\"r t data\" style=\"width: 139.133px;vertical-align: middle;height: 15px;text-align: center\" scope=\"col\">\n<div class=\"stacked-cell\">\n<div>21<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>These data can also be evaluated using the two-sample chi-square Webulator, for an ordinal scaled problem with 5 outcomes as shown below:<\/p>\n<p>https:\/\/health.ahs.upei.ca\/webulators\/fiveby2.html<\/p>\n<p><code><\/p>\n<div id=\"h5p-14\">\n<div class=\"h5p-content\" data-content-id=\"14\"><\/div>\n<\/div>\n<p><\/code><\/p>\n<h3>AN ANNOTATED EXAMPLE: Chi-Square Goodness of Fit Test For Two Samples<\/h3>\n<p>The following is an example of the two-group chi-square based on a study of the distribution of cell phone use by individuals relative to motor vehicle collisions.<\/p>\n<p>In 2010, Issar, Kadakia, Tsahakis, Yoneda et al (2013), conducted a study to investigate the link between texting and motor vehicle collisions (MVC).\u00a0 Data were collected using a questionnaire sent to patients attending an orthopaedic trauma clinic. The responses were organized into two groups as follows: Group 1 included patients who were involved in a MVC and were driving the vehicle at the time of the collision, and Group 2 consisted of all other patients attending the orthopedic clinic between October 2010 to March 2011.<\/p>\n<p>In Table 17.3 the frequency of general phone use by Group 1 and Group 2 is presented.\u00a0 Although both frequency data (counts) and percentages are reported, we can use a two-group chi-square goodness of fit analysis to evaluate the frequency data.<\/p>\n<p style=\"text-align: center\">Table 17.3 General Phone Use Frequencies for MVC vs. non-MVC Phone use<a href=\"#_ftn1\">[1]<\/a><\/p>\n<table class=\"aligncenter\">\n<tbody>\n<tr>\n<td>Phone use<\/p>\n<p>(hours\/week)<\/td>\n<td>Group 1: MVC<\/td>\n<td>Group 2: Non-MVC<\/td>\n<\/tr>\n<tr>\n<td>0 \u2013 1<\/td>\n<td>15 (26.3%)<\/td>\n<td>32 (26.7%)<\/td>\n<\/tr>\n<tr>\n<td>1 \u2013 2<\/td>\n<td>11 (19.3)<\/td>\n<td>24 (20.0%)<\/td>\n<\/tr>\n<tr>\n<td>2 \u2013 3<\/td>\n<td>10 (17.5%)<\/td>\n<td>16 (13.3%)<\/td>\n<\/tr>\n<tr>\n<td>3 \u2013 4<\/td>\n<td>6 (10.5%)<\/td>\n<td>13 (10.8%)<\/td>\n<\/tr>\n<tr>\n<td>&gt;4<\/td>\n<td>15 (26.3%)<\/td>\n<td>35 (29.2%)<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>The data from Table 17.3 are used to determine if the two groups differ in their phone use, measured in hours per week. In order to ensure that the research is not biased, the null hypothesis will be: &#8220;there is no association between MVC group and cell phone use in hours per week&#8221;. Our first step in the evaluation process is to state the expected response pattern. The expected response pattern is consistent with our \u201cexpected distribution\u201d. In other words, in an unbiased research study, we should expect that all possible responses are equally as likely to occur within each of the samples. In the examples presented here, twenty percent of each group should answer each of the response options. We call this the unbiased null hypothesis and state it in terms of frequencies of responses. The null hypothesis for this set of examples is<\/p>\n<p style=\"text-align: center\">H0: frequency response in Group<sub>11&#8230;5<\/sub> = frequency response in Group<sub>21&#8230;5<\/sub><\/p>\n<p>The data responses for this example are presented in Table 17.4 below.\u00a0 The arrangement of these data forms a 2 x 5 contingency table and therefore is analyzed using the standard chi-square formula.<\/p>\n<div>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/chisquFRM.png\" alt=\"\" width=\"181\" height=\"104\" class=\"aligncenter size-full wp-image-432\" srcset=\"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/chisquFRM.png 181w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/chisquFRM-65x37.png 65w\" sizes=\"auto, (max-width: 181px) 100vw, 181px\" \/><\/p>\n<\/div>\n<div>\n<p style=\"text-align: center\"><strong>T<span style=\"font-size: 1em\">able 17.4 Raw Data Used in the 2 x 5 Chi-Square Analysis<\/span><\/strong><\/p>\n<\/div>\n<table class=\"aligncenter\" style=\"width: 305px\">\n<tfoot>\n<tr class=\"shaded\">\n<td style=\"width: 119.85px;text-align: center\"><strong><em>Column Sums = <\/em><\/strong><\/td>\n<td style=\"width: 71.05px;vertical-align: middle;text-align: center\" scope=\"col\"><strong>57<\/strong><\/td>\n<td style=\"width: 75.05px;vertical-align: middle;text-align: center\" scope=\"col\"><strong>10<\/strong><\/td>\n<\/tr>\n<\/tfoot>\n<tbody>\n<tr>\n<td style=\"width: 119.85px\"><em>\u00a0<\/em><\/td>\n<th class=\"shaded\" style=\"width: 70.25px;text-align: center;vertical-align: middle\" scope=\"col\">MVC Group 1<\/th>\n<th class=\"shaded\" style=\"width: 74.25px;text-align: center;vertical-align: middle\" scope=\"col\">Non-MVC Group 2<\/th>\n<\/tr>\n<tr>\n<td style=\"width: 119.85px\"><em>Option 1<\/em><\/td>\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">15<\/td>\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">32<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 119.85px\"><em>Option 2<\/em><\/td>\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">11<\/td>\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">24<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 119.85px\"><em>Option 3<\/em><\/td>\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">10<\/td>\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">16<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 119.85px\"><em>Option 4<\/em><\/td>\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">6<\/td>\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">13<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 119.85px\"><em>Option 5<\/em><\/td>\n<td style=\"width: 71.05px;text-align: center;vertical-align: middle\" scope=\"col\">15<\/td>\n<td style=\"width: 75.05px;text-align: center;vertical-align: middle\" scope=\"col\">35<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>The chi-square test measures how closely the responses in two distributions match.\u00a0 That is, to what extent is the distribution for MVC Group 1 the same as the Non-MVC Group 2. Enter the frequency data for each option from the datasheet in Table 17.4\u00a0 into the corresponding fields of the webulator below. Click through the frames to compute the 2 x 5 chi-square calculations.<\/p>\n<p><code><\/p>\n<div id=\"h5p-14\">\n<div class=\"h5p-content\" data-content-id=\"14\"><\/div>\n<\/div>\n<p><\/code><\/p>\n<div><\/div>\n<p>Using the webulator for the 2 x 5 chi-sqaure we use a stepwise approach to compute the expected values for each cell using the formula\u00a0 (row sum * column sum) \u00f7 grand total.\u00a0 These values are provided in the webulator and shown in the following table.<\/p>\n<p style=\"text-align: center\"><span style=\"text-align: initial;font-size: 1em\"><strong>Table 17.5 Expected values for each cell based on the formula (row sum * column sum) \u00f7 grand total.<\/strong>\u00a0<\/span><\/p>\n<div>\n<table class=\"aligncenter\" style=\"border-collapse: collapse;width: 57.8329%;height: 90px\">\n<tbody>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Expected Cell Values<\/td>\n<td style=\"width: 20.6493%;height: 15px\">MVC Group 1<\/td>\n<td style=\"width: 13.1616%;height: 15px\">Non-MVC Group 2<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Option 1<\/td>\n<td style=\"width: 20.6493%;height: 15px\">0.002<\/td>\n<td style=\"width: 13.1616%;height: 15px\">0.0006<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Option 2<\/td>\n<td style=\"width: 20.6493%;height: 15px\">0.0065<\/td>\n<td style=\"width: 13.1616%;height: 15px\">0.003<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Option 3<\/td>\n<td style=\"width: 20.6493%;height: 15px\">0.31<\/td>\n<td style=\"width: 13.1616%;height: 15px\">0.15<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Option 4<\/td>\n<td style=\"width: 20.6493%;height: 15px\">0.002<\/td>\n<td style=\"width: 13.1616%;height: 15px\">0.001<\/td>\n<\/tr>\n<tr style=\"height: 15px\">\n<td style=\"width: 21.6545%;height: 15px\">Option 5<\/td>\n<td style=\"width: 20.6493%;height: 15px\">0.075<\/td>\n<td style=\"width: 13.1616%;height: 15px\">0.035<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>The chi-square score also referred to as the chi-square observed is produced in the final frame of the webulator. After computing the chi-square observed value, we next determine the chi-square critical score from a table of chi-square values. The chi-square critical score presented in these examples represents what we should expect to observe for two sample distributions each with five possible responses. The critical value is determined by computing the \u201cdegrees of freedom\u201d for our response set. The computation of the degrees of freedom is:<\/p>\n<p>degrees of freedom = (number of rows &#8211; 1 ) * (number of columns -1)<br \/>\n[latex]\\therefore[\/latex] degrees of freedom = (5-1) x (2-1)<br \/>\ndegrees of freedom = (4) x (1)<br \/>\ndegrees of freedom = 4<\/p>\n<p>[latex]\\therefore[\/latex] the <em><strong>chi-square critical value<\/strong><\/em> for (d.f.=4)\u00a0 at p&lt;0.05 = 9.49<\/p>\n<p>Once we have calculated the chi-square observed and then determined the chi-square critical then we establish a decision about whether or not to accept or reject the null hypothesis for this comparison. Recall that our null hypothesis was initially set as: the distribution of responses for the MVC Group across the response options would be equal to the distribution of responses for the MVC Group across the response options. Therefore our decision to accept or reject the null hypothesis follows the decision rule: If the \u201cchi-square observed value \u201d is greater than (<strong>\u203a)<\/strong>\u00a0the \u201cchi-square critical value of\u00a0<strong>9.49<\/strong>\u201d, we would reject the null hypothesis and state that the two distributions ARE NOT EQUAL.\u00a0 However, if the \u201cchi-square observed value \u201d is less than (<strong>\u2039)<\/strong>\u00a0the \u201cchi-square critical value of\u00a0<strong>9.49<\/strong>\u201d, we would ACCEPT the null hypothesis and state that the two distributions ARE EQUAL.<\/p>\n<p>From our computations, we can see that the chi-square observed value is<strong> 0.59,<\/strong> which is less than the chi-square critical value of <strong>9.49<\/strong> and therefore we accept the null hypothesis that the two distributions are equal.\u00a0 Restating this outcome with specific reference to texting and MVCs in the Issar study we conclude that the MVC group does not differ from the non-MVC group with respect to their phone hour use per week.<\/p>\n<h4>SAS Code used to verify the two group Chi-Square Goodness of Fit<\/h4>\n<p>In this example, we computed the differences in cell phone use by motor vehicle collisions. The following is the SAS code applied to the computations produced above.<\/p>\n<p>The study intended to measure whether the group of individuals that were involved in motor vehicle collisions had the same profile of cell-phone use as the group that were not involved in motor vehicle collisions.\u00a0 The data set was comprised of three variables:<\/p>\n<p>1) Phone Use:\u00a0 where 1 = &#8216;0 to 1 hrs\/wk&#8217;,\u00a0 2 = &#8216;1 to 2 hrs\/wk\u2019, \u00a03 = &#8216;2 to 3 hrs\/wk&#8217;, 4 = &#8216;3 to 4 hrs\/wk&#8217;, 5 = &#8216;&gt; 4 hrs\/wk&#8217;;\u00a0 2) Involvement in a motor vehicle collision: 1 = &#8216;MVC&#8217;,\u00a0 2 = &#8216;No-MVC&#8217;;\u00a0 and a third variable which was the number of events reported.<\/p>\n<div class=\"textbox textbox--examples\">\n<header class=\"textbox__header\">\n<p class=\"textbox__title\">The relevant SAS code used to process this two group chi-square goodness of fit is shown here<\/p>\n<\/header>\n<div class=\"textbox__content\">\n<p>PROC FORMAT;<br \/>\nVALUE OPTFMT 1 = &#8216;0 TO 1 HRS\/WK&#8217;<br \/>\n2 = &#8216;1 TO 2 HRS\/WK&#8217;<br \/>\n3 = &#8216;2 TO 3 HRS\/WK&#8217;<br \/>\n4 = &#8216;3 TO 4 HRS\/WK&#8217;<br \/>\n5 = &#8216;&gt; 4 HRS\/WK&#8217;;<\/p>\n<p>VALUE MVCFMT 1 = &#8216;MVC&#8217;\u00a0\u00a0 2 = &#8216;NO-MVC&#8217;;<\/p>\n<p>DATA CHIMVC;<br \/>\nTITLE &#8216;PHONE USE AND MOTOR VEHICLE COLLISIONS &#8216;;<br \/>\nINPUT PHONEUSE MVC NUM_RPRT @@;<\/p>\n<p>LABEL PHONEUSE = &#8220;HOURS OF PHONE USE PER WEEK&#8221;;<br \/>\nLABEL MVC = &#8220;MOTOR VEHICLE COLLISION&#8221;;<br \/>\nLABEL NUM_RPRT = &#8220;NUMBER OF EVENTS REPORTED&#8221;;<\/p>\n<p>DATALINES;<br \/>\n1 1 15 1 2 32 2 1 11 2 2 24 3 1 10 3 2 16 4 1\u00a0 6 4 2 13 5 1 15 5 2 35<br \/>\n;<\/p>\n<p>PROC SORT; BY\u00a0 MVC;<br \/>\n\/* Define the axis characteristics *\/<br \/>\naxis1 offset=(0,70) minor=none;<br \/>\naxis2 label=(angle=90);<br \/>\npattern1 value=solid color=cx7c95ca;<br \/>\npattern2 value=solid color=cxde7e6f;<br \/>\nPROC GCHART;<br \/>\nBLOCK PHONEUSE \/ SUBGROUP=MVC<br \/>\ndiscrete SUMVAR=NUM_RPRT<br \/>\nCOUTLINE=RED WOUTLINE=1 raxis=axis2;<br \/>\nTITLE1 &#8216;BLOCK CHART OF MVC BY PHONE HOURS OF USE&#8217;;<br \/>\nFORMAT PHONEUSE OPTFMT. MVC MVCFMT. ;<\/p>\n<p>PROC FREQ; TABLES PHONEUSE*MVC \/ CHISQ ;<br \/>\nWEIGHT NUM_RPRT;<br \/>\nFORMAT PHONEUSE OPTFMT. MVC MVCFMT. ;<br \/>\nTITLE &#8216;COMPARISON OF MVCS BY WEEKLY CELL PHONE USE&#8217;;<\/p>\n<\/div>\n<\/div>\n<p style=\"text-align: center\"><strong>Figure 17.1 Block Chart of the Frequency Distribution for Number of MVCs<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B.png\" alt=\"\" width=\"588\" height=\"279\" class=\"aligncenter size-full wp-image-1697\" srcset=\"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B.png 588w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B-300x142.png 300w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B-65x31.png 65w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B-225x107.png 225w, https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-content\/uploads\/sites\/49\/2020\/04\/BLOCK17B-350x166.png 350w\" sizes=\"auto, (max-width: 588px) 100vw, 588px\" \/><\/p>\n<p><strong>Table 17.6 <\/strong><strong style=\"text-align: initial;font-size: 1em\">Statistics for Table of Phone Use by Motor Vehicle Collision<\/strong><\/p>\n<div style=\"margin: auto;\">\n<table>\n<thead>\n<tr>\n<td>Statistic<\/td>\n<td>DF<\/td>\n<td>Value<\/td>\n<td>Prob<\/td>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Chi-Square<\/td>\n<td>4<\/td>\n<td>0.5924<\/td>\n<td>0.9639<\/td>\n<\/tr>\n<tr>\n<td>Likelihood Ratio Chi-Square<\/td>\n<td>4<\/td>\n<td>0.5800<\/td>\n<td>0.9653<\/td>\n<\/tr>\n<tr>\n<td>Mantel-Haenszel Chi-Square<\/td>\n<td>1<\/td>\n<td>0.0327<\/td>\n<td>0.8566<\/td>\n<\/tr>\n<tr>\n<td>Phi Coefficient<\/td>\n<td><\/td>\n<td>0.0579<\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td>Contingency Coefficient<\/td>\n<td><\/td>\n<td>0.0578<\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td>Cramer&#8217;s V<\/td>\n<td><\/td>\n<td>0.0579<\/td>\n<td><strong style=\"font-size: 1em\">\u00a0<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\n<div>\n<p><a href=\"#_ftnref1\">[1]<\/a> From Issar, Kadakia, Tsahakis, Yoneda et al (2013): The link between texting and motor vehicle collision frequency in the orthopaedic trauma population. J Inj Violence Res. 2013 Jun; 5(2): 95-100.<\/p>\n<\/div>\n<\/div>\n","protected":false},"author":56,"menu_order":4,"template":"","meta":{"pb_show_title":"on","pb_short_title":"","pb_subtitle":"","pb_authors":[],"pb_section_license":""},"chapter-type":[],"contributor":[],"license":[],"class_list":["post-386","chapter","type-chapter","status-publish","hentry"],"part":34,"_links":{"self":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/386","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters"}],"about":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/types\/chapter"}],"author":[{"embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/users\/56"}],"version-history":[{"count":25,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/386\/revisions"}],"predecessor-version":[{"id":1674,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/386\/revisions\/1674"}],"part":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/parts\/34"}],"metadata":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/386\/metadata\/"}],"wp:attachment":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/media?parent=386"}],"wp:term":[{"taxonomy":"chapter-type","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapter-type?post=386"},{"taxonomy":"contributor","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/contributor?post=386"},{"taxonomy":"license","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/license?post=386"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}