{"id":487,"date":"2015-07-16T09:08:59","date_gmt":"2015-07-16T13:08:59","guid":{"rendered":"http:\/\/sites.berry.edu\/vbissonnette\/?page_id=487"},"modified":"2016-06-22T07:37:22","modified_gmt":"2016-06-22T11:37:22","slug":"t-test-for-dependent-groups-solution","status":"publish","type":"page","link":"https:\/\/sites.berry.edu\/vbissonnette\/t-test-for-dependent-groups-solution\/","title":{"rendered":"T Test for Dependent Groups Solution"},"content":{"rendered":"<h3>Example homework problem:<\/h3>\n<p>Twelve people completed a difficult hand-eye coordination task twice: once in a quiet room, and once in the same room while loud rock-and-roll music was being played. The order in which subjects experienced these conditions was counterbalanced: half performed in the quiet environment first, half performed in the loud environment first.<\/p>\n<p>The researcher measured the number of errors committed by the participant while\u00a0 performing. Thus, the lower the score, the better the performance. Here are the results:<\/p>\n<table style=\"width: 500px;border: 1px solid black\">\n<tbody>\n<tr>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">Participant:<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">1<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">2<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">3<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">4<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">5<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">6<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">7<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">8<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">9<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">10<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">11<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">12<\/td>\n<\/tr>\n<tr>\n<td>Quiet Environment:<\/td>\n<td>14<\/td>\n<td>21<\/td>\n<td>24<\/td>\n<td>16<\/td>\n<td>18<\/td>\n<td>20<\/td>\n<td>15<\/td>\n<td>20<\/td>\n<td>17<\/td>\n<td>16<\/td>\n<td>19<\/td>\n<td>12<\/td>\n<\/tr>\n<tr>\n<td>Loud Environment:<\/td>\n<td>21<\/td>\n<td>22<\/td>\n<td>21<\/td>\n<td>19<\/td>\n<td>18<\/td>\n<td>25<\/td>\n<td>17<\/td>\n<td>18<\/td>\n<td>21<\/td>\n<td>24<\/td>\n<td>21<\/td>\n<td>15<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Was there a significant difference in performance between the two treatment conditions\u00a0 (alpha = .05)?<\/p>\n<hr \/>\n<p>The above problem involves an experiment with two treatment conditions. The goal of your<br \/>\ntest is to see if there is significant mean difference between the two treatment conditions.<\/p>\n<p>We will test for a significant mean difference between the treatment conditions with a <u>t-test for related samples<\/u>:<\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest1.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-101 aligncenter\" src=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest1.png\" alt=\"dttest1\" width=\"233\" height=\"52\" \/><\/a>This <i>t<\/i> test is really simple &#8212; <i>t<\/i> is equal to the mean of the difference scores divided by the standard error of the difference scores. You will see how to get the difference scores below. n equals the number of participants, or the number of pairs of scores.<\/p>\n<p><b>Compute test statistic<\/b>. First, compute a difference score for each subject: i.e., for each subject, subtract their score in the loud environment from their score in the quiet environment. Here are your difference scores:<\/p>\n<table style=\"width: 500px;border: 1px solid black\">\n<tbody>\n<tr>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">Participant:<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">1<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">2<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">3<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">4<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">5<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">6<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">7<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">8<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">9<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">10<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">11<\/td>\n<td style=\"border-bottom-style: solid;border-bottom-width: 1px;border-bottom-color: black\">12<\/td>\n<\/tr>\n<tr>\n<td class=\"lf\">Quiet Environment:<\/td>\n<td>14<\/td>\n<td>21<\/td>\n<td>24<\/td>\n<td>16<\/td>\n<td>18<\/td>\n<td>20<\/td>\n<td>15<\/td>\n<td>20<\/td>\n<td>17<\/td>\n<td>16<\/td>\n<td>19<\/td>\n<td>12<\/td>\n<\/tr>\n<tr>\n<td class=\"lf\">Loud Environment:<\/td>\n<td>21<\/td>\n<td>22<\/td>\n<td>21<\/td>\n<td>19<\/td>\n<td>18<\/td>\n<td>25<\/td>\n<td>17<\/td>\n<td>18<\/td>\n<td>21<\/td>\n<td>24<\/td>\n<td>21<\/td>\n<td>15<\/td>\n<\/tr>\n<tr>\n<td>Difference Score:<\/td>\n<td>-7<\/td>\n<td>-1<\/td>\n<td>+3<\/td>\n<td>-3<\/td>\n<td>0<\/td>\n<td>-5<\/td>\n<td>-2<\/td>\n<td>+2<\/td>\n<td>-4<\/td>\n<td>-8<\/td>\n<td>-2<\/td>\n<td>-3<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Now, your analysis will involve only these difference scores. Compute the mean and the standard deviation of these difference scores. In our study, \u03a3D = -30, \u03a3D\u00b2 = 194, and n = 12. So, the mean of the difference scores is equal to -2.50, and the standard deviation of the difference scores is equal to 3.29. If you would like help computing these descriptive statistics, read the documentation for the <a href=\"http:\/\/sites.berry.edu\/vbissonnette\/index\/stats-homework\/documentation\/explore-data\/\">explore procedure<\/a>. Compute these statistics for yourself now. When you compute <i>t<\/i>, you will find that:<\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-102 aligncenter\" src=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2.png\" alt=\"dttest2\" width=\"344\" height=\"54\" srcset=\"https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2.png 344w, https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2-300x47.png 300w\" sizes=\"auto, (max-width: 344px) 100vw, 344px\" \/><\/a><b>Conduct hypothesis test<\/b>. In our case, n = 12 so the <i>df<\/i> for our <i>t<\/i> test will be 11. Let us assume that we will employ a non-directional (i.e., two-tailed) test with alpha = .05. From your <a href=\"https:\/\/sites.berry.edu\/vbissonnette\/index\/statistical-tables\/\">table of critical values for the <i>t<\/i> test<\/a>, you will find that if the absolute value of our obtained <i>t<\/i> is greater in value than 2.201, we would conclude that the noise level in the environment had a significant effect on performance.<\/p>\n<p>Since 2.633 is greater than 2.201, we would conclude that the participants&#8217; performance <u>was<\/u> significantly affected by the noise level in the environment.<\/p>\n<p><b>Effect size<\/b>. To describe the effect size for this study, we will first compute <i>r<\/i>\u00b2:<\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2b.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-104 aligncenter\" src=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2b.png\" alt=\"dttest2b\" width=\"324\" height=\"45\" srcset=\"https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2b.png 324w, https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2b-300x42.png 300w\" sizes=\"auto, (max-width: 324px) 100vw, 324px\" \/><\/a><i>r<\/i>\u00b2 is an estimate of the proportion of variance in our dependent variable that can be accounted for by our manipulation of the independent variable. So, we could conclude that 19% of the variance in recall was due to our manipulation of the encoding instructions.<\/p>\n<p>However, many researchers prefer to use an <u>unbiased<\/u> effect size estimate &#8212; one that takes into account the fact that we are doing small sample research. So, we will also compute\u00a0 <u>Omega Squared<\/u>:<\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2c.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-105 aligncenter\" src=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2c.png\" alt=\"dttest2c\" width=\"424\" height=\"45\" srcset=\"https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2c.png 424w, https:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2c-300x32.png 300w\" sizes=\"auto, (max-width: 424px) 100vw, 424px\" \/><\/a>We would conclude that our manipulation of encoding instructions accounted for 14% of the variance in memory performance.<\/p>\n<p>Finally, we will compute Cohen&#8217;s <i>D<\/i>:<\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2a.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-full wp-image-103 aligncenter\" src=\"http:\/\/sites.berry.edu\/vbissonnette\/wp-content\/uploads\/sites\/21\/2015\/07\/dttest2a.png\" alt=\"dttest2a\" width=\"238\" height=\"48\" \/><\/a>which is simply the mean of the difference scores divided by the standard deviation of the difference scores. What Cohen&#8217;s <i>D<\/i> tells us is that there is .76 of a standard deviation difference between our groups.<\/p>\n<hr \/>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/index\/stats-homework\/documentation\/t-test-for-dependent-groups\/\">Return to Dependent <i>t<\/i> Test.<\/a><\/p>\n<p><a href=\"http:\/\/sites.berry.edu\/vbissonnette\/index\/stats-homework\/documentation\/\">Return to Table of Contents<\/a><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Example homework problem: Twelve people completed a difficult hand-eye coordination task twice: once in a quiet room, and once in the same room while loud rock-and-roll music was being played. [&hellip;]<\/p>\n","protected":false},"author":34,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","meta":{"site-container-style":"default","site-container-layout":"default","site-sidebar-layout":"default","site-transparent-header":"default","disable-article-header":"default","disable-site-header":"default","disable-site-footer":"default","disable-content-area-spacing":"default","footnotes":""},"class_list":["post-487","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/pages\/487","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/users\/34"}],"replies":[{"embeddable":true,"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/comments?post=487"}],"version-history":[{"count":9,"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/pages\/487\/revisions"}],"predecessor-version":[{"id":840,"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/pages\/487\/revisions\/840"}],"wp:attachment":[{"href":"https:\/\/sites.berry.edu\/vbissonnette\/wp-json\/wp\/v2\/media?parent=487"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}