{"id":770,"date":"2020-05-28T10:23:51","date_gmt":"2020-05-28T14:23:51","guid":{"rendered":"http:\/\/pressbooks.library.upei.ca\/montelpare\/?post_type=chapter&#038;p=770"},"modified":"2020-08-24T14:16:30","modified_gmt":"2020-08-24T18:16:30","slug":"fishers-exact-and-the-phi-coefficient","status":"publish","type":"chapter","link":"https:\/\/pressbooks.library.upei.ca\/montelpare\/chapter\/fishers-exact-and-the-phi-coefficient\/","title":{"raw":"Fisher's Exact and the Phi Coefficient","rendered":"Fisher&#8217;s Exact and the Phi Coefficient"},"content":{"raw":"<h1>Part 2: Calculating Fisher\u2019s Exact Statistic<\/h1>\r\nIn the chi-square test statistic shown in the previous chapter, we were interested in measuring the association between breastfeeding duration and the mother\u2019s level of education that she had completed.\u00a0 This is not a <strong>causal<\/strong> model but <strong>a measure of association<\/strong> that lets us evaluate the relationship between two independent measures. We began with <strong>the null hypothesis<\/strong> that there was <strong>no association<\/strong> between the two variables, but after testing the association with the chi-square test and finding that the chi-square estimate that we calculated exceeded the chi-square estimate expected we rejected the null hypothesis and our conclusion was that there appears to be a relationship between the level of maternal education and breastfeeding duration.\r\n\r\nOur decision to reject the null hypothesis was based on the chi-square estimate that we calculated is compared to a critical value associated with a 95% probability that our observed estimate was representative of that which we should find in a normal population. We could however be more precise than 95% and compute the exact probability of the chi-square statistic that we calculated by using the Fisher\u2019s Exact test.\r\n\r\nThe formula for the Fisher\u2019s Exact test is shown here as:\r\n<p style=\"text-align: center\">[latex]p = {(a+b)! (c+d)! (a+c)! (b+d)!\\over (n! <span>\\times <\/span>a!\u00a0 <span>\\times <\/span>b! <span>\\times<\/span> c! <span>\\times<\/span> d!)}[\/latex]<\/p>\r\nThe term n! refers to \"n\"- factorial and it is computed by simply recursively calculating out the run of n x (n-1) x (n-2) x (n-3) \u2026 until (1).\u00a0 So that 6! is actually 6 x (6-1) x (6-2) x (6-3) x (6-4) x (6-5) or in simpler terms 6! is 6 x 5 x 4 x 3 x 2 x 1.\r\n\r\nApplying the Fisher\u2019s exact test to our scenario we would compute the following exact probability for our chi-square statistic, where a=43; b=27; c=21; and d=34;\r\n\r\nNote that you will have difficulty computing the exact probability with numbers as large as those represented by a, b, c, and d. Therefore, we can reduce this computation by using the following SAS code.\u00a0 This approach demonstrates the versatility of the SAS programming language to enable complex computations without requiring an apriori dataset.\r\n<div class=\"textbox textbox--examples\"><header class=\"textbox__header\">\r\n<p class=\"textbox__title\">SAS Code to compute Fisher's Exact Test from known values<\/p>\r\n\r\n<\/header>\r\n<div class=\"textbox__content\">\r\n\r\nOPTIONS PAGESIZE=55 LINESIZE=120 CENTER DATE;\r\nDATA FACT;\r\nX1=FACT(70); X2=FACT(55); X3=FACT(64); X4=FACT(61);\r\nY1=FACT(125); Y2=FACT(43); Y3=FACT(27); Y4=FACT(21); Y5=FACT(34);\r\n\r\n\/* REDUCE THESE FACTORIALS TO COMPUTE FISHER\u2019S EXACT.\r\nIMPROVE THE EFFICIENCY OF THE REDUCTION BY MATCHING LARGEST\r\nNUMERATORS AND DENOMINATORS TO CANCEL NUMBERS WITHIN THE SEQUENCE *\/\r\n\r\nREDUCE1=(X1\/Y1);\u00a0 REDUCE2=(X2\/Y2);\u00a0 REDUCE3=(X3\/Y5);\u00a0 REDUCE4=(X4\/Y3);\r\nREDUCE5=(1\/Y4);\r\n\r\nOUTCOME=ROUND (REDUCE1*REDUCE2*REDUCE3*REDUCE4*REDUCE5, 0.001);\r\n\r\nPROC PRINT DATA=FACT;\r\nVAR X1 X2 X3 X4 Y1 Y2 Y3 Y4 Y5 REDUCE1 REDUCE2 REDUCE3 REDUCE4 REDUCE5 <span style=\"color: #0000ff\">OUTCOME<\/span>;\r\nRUN;\r\n\r\n<\/div>\r\n<\/div>\r\nThe SAS code above produces the following results.\r\n<table style=\"border-collapse: collapse;width: 100%\" border=\"0\">\r\n<thead>\r\n<tr class=\"border\">\r\n<th class=\"shaded\" style=\"width: 20.1835%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X1<\/strong><\/th>\r\n<th class=\"shaded\" style=\"width: 19.2661%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X2<\/strong><\/th>\r\n<th class=\"shaded\" style=\"width: 19.5719%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X3<\/strong><\/th>\r\n<th class=\"shaded\" style=\"width: 19.7248%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X4<\/strong><\/th>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr class=\"border\">\r\n<td style=\"width: 20.1835%;text-align: center\">1.1979E100<\/td>\r\n<td style=\"width: 19.2661%;text-align: center\">1.2696E73<\/td>\r\n<td style=\"width: 19.5719%;text-align: center\">1.2689E89<\/td>\r\n<td style=\"width: 19.7248%;text-align: center\">5.0758E83<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<table style=\"width: 630px;height: 78px\" border=\"0\">\r\n<thead>\r\n<tr class=\"shaded\">\r\n<th class=\"shaded\" style=\"width: 112.033px;text-align: center\" scope=\"row\"><strong>VARIABLE: Y1<\/strong><\/th>\r\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y2<\/strong><\/td>\r\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y3<\/strong><\/td>\r\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y4<\/strong><\/td>\r\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y5<\/strong><\/td>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr class=\"border\">\r\n<td style=\"width: 112.033px;text-align: center\">1.8827E209<\/td>\r\n<td style=\"width: 112.033px;text-align: center\">6.0415E52<\/td>\r\n<td style=\"width: 112.033px;text-align: center\">1.0889E28<\/td>\r\n<td style=\"width: 112.033px;text-align: center\">5.1091E19<\/td>\r\n<td style=\"width: 112.033px;text-align: center\">2.9523E38<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<table style=\"width: 632px;height: 59px\">\r\n<thead>\r\n<tr class=\"shaded\">\r\n<td style=\"text-align: center;width: 98.3833px\"><strong>REDUCE_1<\/strong><\/td>\r\n<td style=\"text-align: center;width: 88.4167px\"><strong>REDUCE_2<\/strong><\/td>\r\n<td style=\"text-align: center;width: 88.85px\"><strong>REDUCE_3<\/strong><\/td>\r\n<td style=\"text-align: center;width: 88.65px\"><strong>REDUCE_4<\/strong><\/td>\r\n<td style=\"text-align: center;width: 89.8667px\"><strong>REDUCE_5<\/strong><\/td>\r\n<td style=\"text-align: center;width: 94.2px\"><span style=\"color: #0000ff\"><strong>OUTCOME<\/strong><\/span><\/td>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr class=\"border\">\r\n<td style=\"width: 98.3833px;text-align: center\">6.3625E-110<\/td>\r\n<td style=\"width: 88.4167px;text-align: center\">2.1015E20<\/td>\r\n<td style=\"width: 88.85px;text-align: center\">4.2979E50<\/td>\r\n<td style=\"width: 88.65px;text-align: center\">4.6615E55<\/td>\r\n<td style=\"width: 89.8667px;text-align: center\">1.9573E-20<\/td>\r\n<td style=\"width: 94.2px;text-align: center\"><span style=\"color: #0000ff\">.005243165<\/span><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\nThe <span style=\"color: #0000ff\">OUTCOME<\/span> value shown in the table above is the EXACT P-value which when rounded is p = 0.005.\r\n\r\nWe could also compute the Fisher's Exact value by hand using the following formula with the following cell values:\u00a0 a=43, b= 27, c=21 and d=34.\r\n<p style=\"text-align: center\">[latex]p = {(a+b)! (c+d)! (a+c)! (b+d)!\\over (n! <span>\\times <\/span>a!\u00a0 <span>\\times <\/span>b! <span>\\times<\/span> c! <span>\\times<\/span> d!)}[\/latex]<\/p>\r\n<p style=\"text-align: center\">[latex]p = {(43+27)! (21+34)! (43+21)! (27+34)!\\over (125! <span>\\times <\/span>43!\u00a0 <span>\\times 27<\/span>! <span>\\times<\/span> 21! <span>\\times<\/span> 34!)}[\/latex]<\/p>\r\n<p style=\"text-align: center\">[latex]p = {(70)! (55)! (64)! (61)!\\over (125! <span>\\times <\/span>43!\u00a0 <span>\\times <\/span>27! <span>\\times<\/span> 21! <span>\\times<\/span> 34!)}[\/latex]<\/p>\r\n<p style=\"text-align: center\">[latex]p = {0.005243165}[\/latex]<\/p>\r\n\r\n\r\n<hr \/>\r\n\r\n<h1>Part 3: Calculating Associations in 2 x 2 tables with the Phi Coefficient<\/h1>\r\nIn addition to computing the exact probability for statistical comparison, we can also determine the strength of the association between the two variables using a simple computation to produce the <span style=\"color: #3366ff\"><strong>phi-coefficient<\/strong><\/span>. The phi-coefficient provides an estimate of association in a 2 x 2 table.\u00a0 If there is no association between the rows and columns then the outcome is 0. The maximum value of phi is 1, which indicates an extremely strong relationship. It is also common to observe that when there appears to be a very low probability associated with a chi-square outcome, the phi-coefficient may also appear to demonstrate a low estimate.\r\n\r\n<strong>The formula for the phi coefficient is<\/strong>: \u00a0 [latex]{\\phi^2} = {\\chi^2 \\over n} = {\\phi ={\\sqrt {\\chi^2 \\over n}}} [\/latex]\r\n<p style=\"text-align: left\">In the chi-square example shown in the previous chapter and in the calculation of the Fisher's Exact Test shown above, the Phi Coefficient is reported in the output in that was generated by our SAS program.<\/p>\r\n<strong>Statistics for Table of ROW by COL from the original chi-square\r\n<\/strong>\r\n<div align=\"center\">\r\n<table>\r\n<thead>\r\n<tr>\r\n<td><strong>Statistic<\/strong><\/td>\r\n<td><strong>DF<\/strong><\/td>\r\n<td><strong>Value<\/strong><\/td>\r\n<td><strong>Prob<\/strong><\/td>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\"><strong>Chi-Square<\/strong><\/span><\/td>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\">1<\/span><\/td>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\">6.6617<\/span><\/td>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\">0.0099<\/span><\/td>\r\n<\/tr>\r\n<tr>\r\n<td><strong>Likelihood Ratio Chi-Square<\/strong><\/td>\r\n<td>1<\/td>\r\n<td>6.7197<\/td>\r\n<td>0.0095<\/td>\r\n<\/tr>\r\n<tr>\r\n<td><strong>Continuity Adj. Chi-Square<\/strong><\/td>\r\n<td>1<\/td>\r\n<td>5.7638<\/td>\r\n<td>0.0164<\/td>\r\n<\/tr>\r\n<tr>\r\n<td><strong>Mantel-Haenszel Chi-Square<\/strong><\/td>\r\n<td>1<\/td>\r\n<td>6.6084<\/td>\r\n<td>0.0101<\/td>\r\n<\/tr>\r\n<tr>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\"><strong>Phi Coefficient<\/strong><\/span><\/td>\r\n<td><\/td>\r\n<td><span style=\"color: #0000ff;background-color: #ffff00\">0.2309<\/span><\/td>\r\n<td><\/td>\r\n<\/tr>\r\n<tr>\r\n<td><strong>Contingency Coefficient<\/strong><\/td>\r\n<td><\/td>\r\n<td>0.2249<\/td>\r\n<td><\/td>\r\n<\/tr>\r\n<tr>\r\n<td><strong>Cramer's V<\/strong><\/td>\r\n<td><\/td>\r\n<td>0.2309<\/td>\r\n<td><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<\/div>\r\n<p style=\"text-align: left\">The Phi Coefficient was reported as 0.2309 which is approximately the same as the value we can compute by hand from the formula shown here:<\/p>\r\n<p style=\"text-align: center\">[latex]{\\phi^2} = {\\chi^2 \\over n} = {\\phi ={\\sqrt {\\chi^2 \\over n}}} = {\\phi ={\\sqrt {6.66 \\over 125}}} = 0.23 [\/latex]<\/p>\r\nThe Phi Coefficient reported here demonstrates that while the chi-square result was significant, and thereby indicating a significant association, the actual measure of association is low at 0.23.\r\n<div>\r\n<div>\r\n\r\n&nbsp;\r\n\r\n<\/div>\r\n<\/div>","rendered":"<h1>Part 2: Calculating Fisher\u2019s Exact Statistic<\/h1>\n<p>In the chi-square test statistic shown in the previous chapter, we were interested in measuring the association between breastfeeding duration and the mother\u2019s level of education that she had completed.\u00a0 This is not a <strong>causal<\/strong> model but <strong>a measure of association<\/strong> that lets us evaluate the relationship between two independent measures. We began with <strong>the null hypothesis<\/strong> that there was <strong>no association<\/strong> between the two variables, but after testing the association with the chi-square test and finding that the chi-square estimate that we calculated exceeded the chi-square estimate expected we rejected the null hypothesis and our conclusion was that there appears to be a relationship between the level of maternal education and breastfeeding duration.<\/p>\n<p>Our decision to reject the null hypothesis was based on the chi-square estimate that we calculated is compared to a critical value associated with a 95% probability that our observed estimate was representative of that which we should find in a normal population. We could however be more precise than 95% and compute the exact probability of the chi-square statistic that we calculated by using the Fisher\u2019s Exact test.<\/p>\n<p>The formula for the Fisher\u2019s Exact test is shown here as:<\/p>\n<p style=\"text-align: center\">[latex]p = {(a+b)! (c+d)! (a+c)! (b+d)!\\over (n! <span>\\times <\/span>a!\u00a0 <span>\\times <\/span>b! <span>\\times<\/span> c! <span>\\times<\/span> d!)}[\/latex]<\/p>\n<p>The term n! refers to &#8220;n&#8221;- factorial and it is computed by simply recursively calculating out the run of n x (n-1) x (n-2) x (n-3) \u2026 until (1).\u00a0 So that 6! is actually 6 x (6-1) x (6-2) x (6-3) x (6-4) x (6-5) or in simpler terms 6! is 6 x 5 x 4 x 3 x 2 x 1.<\/p>\n<p>Applying the Fisher\u2019s exact test to our scenario we would compute the following exact probability for our chi-square statistic, where a=43; b=27; c=21; and d=34;<\/p>\n<p>Note that you will have difficulty computing the exact probability with numbers as large as those represented by a, b, c, and d. Therefore, we can reduce this computation by using the following SAS code.\u00a0 This approach demonstrates the versatility of the SAS programming language to enable complex computations without requiring an apriori dataset.<\/p>\n<div class=\"textbox textbox--examples\">\n<header class=\"textbox__header\">\n<p class=\"textbox__title\">SAS Code to compute Fisher&#8217;s Exact Test from known values<\/p>\n<\/header>\n<div class=\"textbox__content\">\n<p>OPTIONS PAGESIZE=55 LINESIZE=120 CENTER DATE;<br \/>\nDATA FACT;<br \/>\nX1=FACT(70); X2=FACT(55); X3=FACT(64); X4=FACT(61);<br \/>\nY1=FACT(125); Y2=FACT(43); Y3=FACT(27); Y4=FACT(21); Y5=FACT(34);<\/p>\n<p>\/* REDUCE THESE FACTORIALS TO COMPUTE FISHER\u2019S EXACT.<br \/>\nIMPROVE THE EFFICIENCY OF THE REDUCTION BY MATCHING LARGEST<br \/>\nNUMERATORS AND DENOMINATORS TO CANCEL NUMBERS WITHIN THE SEQUENCE *\/<\/p>\n<p>REDUCE1=(X1\/Y1);\u00a0 REDUCE2=(X2\/Y2);\u00a0 REDUCE3=(X3\/Y5);\u00a0 REDUCE4=(X4\/Y3);<br \/>\nREDUCE5=(1\/Y4);<\/p>\n<p>OUTCOME=ROUND (REDUCE1*REDUCE2*REDUCE3*REDUCE4*REDUCE5, 0.001);<\/p>\n<p>PROC PRINT DATA=FACT;<br \/>\nVAR X1 X2 X3 X4 Y1 Y2 Y3 Y4 Y5 REDUCE1 REDUCE2 REDUCE3 REDUCE4 REDUCE5 <span style=\"color: #0000ff\">OUTCOME<\/span>;<br \/>\nRUN;<\/p>\n<\/div>\n<\/div>\n<p>The SAS code above produces the following results.<\/p>\n<table style=\"border-collapse: collapse;width: 100%\">\n<thead>\n<tr class=\"border\">\n<th class=\"shaded\" style=\"width: 20.1835%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X1<\/strong><\/th>\n<th class=\"shaded\" style=\"width: 19.2661%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X2<\/strong><\/th>\n<th class=\"shaded\" style=\"width: 19.5719%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X3<\/strong><\/th>\n<th class=\"shaded\" style=\"width: 19.7248%;text-align: center;vertical-align: middle\" scope=\"row\"><strong>VARIABLE: X4<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"border\">\n<td style=\"width: 20.1835%;text-align: center\">1.1979E100<\/td>\n<td style=\"width: 19.2661%;text-align: center\">1.2696E73<\/td>\n<td style=\"width: 19.5719%;text-align: center\">1.2689E89<\/td>\n<td style=\"width: 19.7248%;text-align: center\">5.0758E83<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<table style=\"width: 630px;height: 78px\">\n<thead>\n<tr class=\"shaded\">\n<th class=\"shaded\" style=\"width: 112.033px;text-align: center\" scope=\"row\"><strong>VARIABLE: Y1<\/strong><\/th>\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y2<\/strong><\/td>\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y3<\/strong><\/td>\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y4<\/strong><\/td>\n<td style=\"width: 112.033px;text-align: center\"><strong>VARIABLE: Y5<\/strong><\/td>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"border\">\n<td style=\"width: 112.033px;text-align: center\">1.8827E209<\/td>\n<td style=\"width: 112.033px;text-align: center\">6.0415E52<\/td>\n<td style=\"width: 112.033px;text-align: center\">1.0889E28<\/td>\n<td style=\"width: 112.033px;text-align: center\">5.1091E19<\/td>\n<td style=\"width: 112.033px;text-align: center\">2.9523E38<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<table style=\"width: 632px;height: 59px\">\n<thead>\n<tr class=\"shaded\">\n<td style=\"text-align: center;width: 98.3833px\"><strong>REDUCE_1<\/strong><\/td>\n<td style=\"text-align: center;width: 88.4167px\"><strong>REDUCE_2<\/strong><\/td>\n<td style=\"text-align: center;width: 88.85px\"><strong>REDUCE_3<\/strong><\/td>\n<td style=\"text-align: center;width: 88.65px\"><strong>REDUCE_4<\/strong><\/td>\n<td style=\"text-align: center;width: 89.8667px\"><strong>REDUCE_5<\/strong><\/td>\n<td style=\"text-align: center;width: 94.2px\"><span style=\"color: #0000ff\"><strong>OUTCOME<\/strong><\/span><\/td>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"border\">\n<td style=\"width: 98.3833px;text-align: center\">6.3625E-110<\/td>\n<td style=\"width: 88.4167px;text-align: center\">2.1015E20<\/td>\n<td style=\"width: 88.85px;text-align: center\">4.2979E50<\/td>\n<td style=\"width: 88.65px;text-align: center\">4.6615E55<\/td>\n<td style=\"width: 89.8667px;text-align: center\">1.9573E-20<\/td>\n<td style=\"width: 94.2px;text-align: center\"><span style=\"color: #0000ff\">.005243165<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>The <span style=\"color: #0000ff\">OUTCOME<\/span> value shown in the table above is the EXACT P-value which when rounded is p = 0.005.<\/p>\n<p>We could also compute the Fisher&#8217;s Exact value by hand using the following formula with the following cell values:\u00a0 a=43, b= 27, c=21 and d=34.<\/p>\n<p style=\"text-align: center\">[latex]p = {(a+b)! (c+d)! (a+c)! (b+d)!\\over (n! <span>\\times <\/span>a!\u00a0 <span>\\times <\/span>b! <span>\\times<\/span> c! <span>\\times<\/span> d!)}[\/latex]<\/p>\n<p style=\"text-align: center\">[latex]p = {(43+27)! (21+34)! (43+21)! (27+34)!\\over (125! <span>\\times <\/span>43!\u00a0 <span>\\times 27<\/span>! <span>\\times<\/span> 21! <span>\\times<\/span> 34!)}[\/latex]<\/p>\n<p style=\"text-align: center\">[latex]p = {(70)! (55)! (64)! (61)!\\over (125! <span>\\times <\/span>43!\u00a0 <span>\\times <\/span>27! <span>\\times<\/span> 21! <span>\\times<\/span> 34!)}[\/latex]<\/p>\n<p style=\"text-align: center\">[latex]p = {0.005243165}[\/latex]<\/p>\n<hr \/>\n<h1>Part 3: Calculating Associations in 2 x 2 tables with the Phi Coefficient<\/h1>\n<p>In addition to computing the exact probability for statistical comparison, we can also determine the strength of the association between the two variables using a simple computation to produce the <span style=\"color: #3366ff\"><strong>phi-coefficient<\/strong><\/span>. The phi-coefficient provides an estimate of association in a 2 x 2 table.\u00a0 If there is no association between the rows and columns then the outcome is 0. The maximum value of phi is 1, which indicates an extremely strong relationship. It is also common to observe that when there appears to be a very low probability associated with a chi-square outcome, the phi-coefficient may also appear to demonstrate a low estimate.<\/p>\n<p><strong>The formula for the phi coefficient is<\/strong>: \u00a0 [latex]{\\phi^2} = {\\chi^2 \\over n} = {\\phi ={\\sqrt {\\chi^2 \\over n}}}[\/latex]<\/p>\n<p style=\"text-align: left\">In the chi-square example shown in the previous chapter and in the calculation of the Fisher&#8217;s Exact Test shown above, the Phi Coefficient is reported in the output in that was generated by our SAS program.<\/p>\n<p><strong>Statistics for Table of ROW by COL from the original chi-square<br \/>\n<\/strong><\/p>\n<div style=\"margin: auto;\">\n<table>\n<thead>\n<tr>\n<td><strong>Statistic<\/strong><\/td>\n<td><strong>DF<\/strong><\/td>\n<td><strong>Value<\/strong><\/td>\n<td><strong>Prob<\/strong><\/td>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><span style=\"color: #0000ff;background-color: #ffff00\"><strong>Chi-Square<\/strong><\/span><\/td>\n<td><span style=\"color: #0000ff;background-color: #ffff00\">1<\/span><\/td>\n<td><span style=\"color: #0000ff;background-color: #ffff00\">6.6617<\/span><\/td>\n<td><span style=\"color: #0000ff;background-color: #ffff00\">0.0099<\/span><\/td>\n<\/tr>\n<tr>\n<td><strong>Likelihood Ratio Chi-Square<\/strong><\/td>\n<td>1<\/td>\n<td>6.7197<\/td>\n<td>0.0095<\/td>\n<\/tr>\n<tr>\n<td><strong>Continuity Adj. Chi-Square<\/strong><\/td>\n<td>1<\/td>\n<td>5.7638<\/td>\n<td>0.0164<\/td>\n<\/tr>\n<tr>\n<td><strong>Mantel-Haenszel Chi-Square<\/strong><\/td>\n<td>1<\/td>\n<td>6.6084<\/td>\n<td>0.0101<\/td>\n<\/tr>\n<tr>\n<td><span style=\"color: #0000ff;background-color: #ffff00\"><strong>Phi Coefficient<\/strong><\/span><\/td>\n<td><\/td>\n<td><span style=\"color: #0000ff;background-color: #ffff00\">0.2309<\/span><\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td><strong>Contingency Coefficient<\/strong><\/td>\n<td><\/td>\n<td>0.2249<\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td><strong>Cramer&#8217;s V<\/strong><\/td>\n<td><\/td>\n<td>0.2309<\/td>\n<td><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p style=\"text-align: left\">The Phi Coefficient was reported as 0.2309 which is approximately the same as the value we can compute by hand from the formula shown here:<\/p>\n<p style=\"text-align: center\">[latex]{\\phi^2} = {\\chi^2 \\over n} = {\\phi ={\\sqrt {\\chi^2 \\over n}}} = {\\phi ={\\sqrt {6.66 \\over 125}}} = 0.23[\/latex]<\/p>\n<p>The Phi Coefficient reported here demonstrates that while the chi-square result was significant, and thereby indicating a significant association, the actual measure of association is low at 0.23.<\/p>\n<div>\n<div>\n<p>&nbsp;<\/p>\n<\/div>\n<\/div>\n","protected":false},"author":56,"menu_order":7,"template":"","meta":{"pb_show_title":"on","pb_short_title":"","pb_subtitle":"","pb_authors":[],"pb_section_license":""},"chapter-type":[47],"contributor":[],"license":[],"class_list":["post-770","chapter","type-chapter","status-publish","hentry","chapter-type-standard"],"part":34,"_links":{"self":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/770","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":24,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/770\/revisions"}],"predecessor-version":[{"id":1386,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapters\/770\/revisions\/1386"}],"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\/770\/metadata\/"}],"wp:attachment":[{"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/media?parent=770"}],"wp:term":[{"taxonomy":"chapter-type","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/pressbooks\/v2\/chapter-type?post=770"},{"taxonomy":"contributor","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/contributor?post=770"},{"taxonomy":"license","embeddable":true,"href":"https:\/\/pressbooks.library.upei.ca\/montelpare\/wp-json\/wp\/v2\/license?post=770"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}