<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Proportion test on repeated measures data. in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155550#M8096</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear all.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Wish you all well.&lt;/P&gt;&lt;P&gt;I wish to find out if the proportion of yes to problem is the same between time 0 and 1 given that they had used(used=1). &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;The data structure is as &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;id&amp;nbsp;&amp;nbsp; time&amp;nbsp;&amp;nbsp;&amp;nbsp; used&amp;nbsp;&amp;nbsp;&amp;nbsp; problem&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;1&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;2&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/P&gt;&lt;P&gt;2&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;etc&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My initial thought was &lt;/P&gt;&lt;P&gt;proc genmod data=tmp descending; &lt;/P&gt;&lt;P&gt; class id time used; &lt;/P&gt;&lt;P&gt; model problem=time used time*used / dist=bin link=identity; &lt;/P&gt;&lt;P&gt; repeated sub=id / type=ind; &lt;/P&gt;&lt;P&gt; lsmeans time*used / ilink cl diff;&lt;/P&gt;&lt;P&gt;run; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is this the right approach? Does lsmean give me the right proportion and the proportion difference? :smileyconfused:&lt;/P&gt;&lt;P&gt;Because I was reading this &lt;A href="http://support.sas.com/kb/46/997.html#note"&gt;46997 - Estimating the risk (proportion) difference for matched pairs data with binary response&lt;/A&gt;. &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;and it says "Unlike the default logit link function, the identity link does not ensure that the model produces valid probability estimates. Errors may be result when fitting such models depending on the model and the data." &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;Thank you for your help &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://communities.sas.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 04 Nov 2014 05:20:49 GMT</pubDate>
    <dc:creator>Miracle</dc:creator>
    <dc:date>2014-11-04T05:20:49Z</dc:date>
    <item>
      <title>Proportion test on repeated measures data.</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155550#M8096</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear all.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Wish you all well.&lt;/P&gt;&lt;P&gt;I wish to find out if the proportion of yes to problem is the same between time 0 and 1 given that they had used(used=1). &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;The data structure is as &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;id&amp;nbsp;&amp;nbsp; time&amp;nbsp;&amp;nbsp;&amp;nbsp; used&amp;nbsp;&amp;nbsp;&amp;nbsp; problem&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;1&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;2&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/P&gt;&lt;P&gt;2&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;etc&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My initial thought was &lt;/P&gt;&lt;P&gt;proc genmod data=tmp descending; &lt;/P&gt;&lt;P&gt; class id time used; &lt;/P&gt;&lt;P&gt; model problem=time used time*used / dist=bin link=identity; &lt;/P&gt;&lt;P&gt; repeated sub=id / type=ind; &lt;/P&gt;&lt;P&gt; lsmeans time*used / ilink cl diff;&lt;/P&gt;&lt;P&gt;run; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is this the right approach? Does lsmean give me the right proportion and the proportion difference? :smileyconfused:&lt;/P&gt;&lt;P&gt;Because I was reading this &lt;A href="http://support.sas.com/kb/46/997.html#note"&gt;46997 - Estimating the risk (proportion) difference for matched pairs data with binary response&lt;/A&gt;. &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;and it says "Unlike the default logit link function, the identity link does not ensure that the model produces valid probability estimates. Errors may be result when fitting such models depending on the model and the data." &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;Thank you for your help &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://communities.sas.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Arial, Helvetica, Verdana, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Nov 2014 05:20:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155550#M8096</guid>
      <dc:creator>Miracle</dc:creator>
      <dc:date>2014-11-04T05:20:49Z</dc:date>
    </item>
    <item>
      <title>Re: Proportion test on repeated measures data.</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155551#M8097</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would certainly change from the identity to the logit as the link, especially if the overall incidence is near the extremes (&amp;lt;0.2 or &amp;gt;0.8). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Steve Denham&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Nov 2014 13:45:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155551#M8097</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2014-11-04T13:45:50Z</dc:date>
    </item>
    <item>
      <title>Re: Proportion test on repeated measures data.</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155552#M8098</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Assuming that you want an estimate (point and/or confidence interval) of the difference in those two probabilities, then yes, that code is reasonable (though you don't need the ILINK option when the identity link is used).&amp;nbsp; If you use the default logit link then the differences from the LSMEANS statement will be differences in log odds (equivalently, log odds ratios).&amp;nbsp; See the following note for more, in general, on estimating differences in probabilities:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;A href="http://support.sas.com/kb/37228" title="http://support.sas.com/kb/37228"&gt;37228 - Estimating differences in probabilities with confidence interval&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Nov 2014 18:55:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proportion-test-on-repeated-measures-data/m-p/155552#M8098</guid>
      <dc:creator>StatDave</dc:creator>
      <dc:date>2014-11-05T18:55:18Z</dc:date>
    </item>
  </channel>
</rss>

