<?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 Re: modelling intercept in proc glimmix and robust standard error in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955046#M47770</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15363"&gt;@SteveDenham&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;I would suggest the following code:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;proc glimmix data=mydata plots=residualpanel &lt;FONT color="#FF0000"&gt;method=laplace&lt;/FONT&gt;;
/* you might want to explore method=quad or method=fastquad */
class group condition time;
model Looking= group condition time group*condition group*condition*time /dist=beta link=logit &lt;FONT color="#FF0000"&gt;ddfm=kr2&lt;/FONT&gt; solution;
random intercept / subject=ID type=un;
random  time / subject=ID&lt;FONT color="#FF0000"&gt;(group*condition)&lt;/FONT&gt; type=un; 
run;&lt;/PRE&gt;
&lt;P&gt;(...)&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;[Just to make the red highlighting visible, which was overridden by the automatic syntax highlighting.]&lt;/P&gt;</description>
    <pubDate>Fri, 03 Jan 2025 18:52:29 GMT</pubDate>
    <dc:creator>FreelanceReinh</dc:creator>
    <dc:date>2025-01-03T18:52:29Z</dc:date>
    <item>
      <title>modelling intercept in proc glimmix and robust standard error</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/953913#M47724</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I was wondering if anyone can help me on this. I am not sure whether I am correctly specifying the random intercept in my model. I need some advices. I am interested in understanding if there are differences in looking behaviours between 5 groups of children, between 2 conditions (condition 1 and 2). Looking behaviours were collected at 2 time points (time 1 and time 2 - repeated measure). I want to model a random intercept for each subject and fit random intercept for time. The model fits the beta distribution as the outcome variable is proportion data using the logit link function (values vary between 0 and 1).&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;Example of my data&lt;/P&gt;&lt;P&gt;ID&amp;nbsp; &amp;nbsp;Group&amp;nbsp; &amp;nbsp;Time&amp;nbsp; &amp;nbsp;Condition&amp;nbsp; Looking&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0&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; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0.87&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 0.22&lt;/P&gt;&lt;P&gt;2&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;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; 0.97&lt;/P&gt;&lt;P&gt;2&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;2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 0.30&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;This is my code&lt;/P&gt;&lt;P&gt;proc glimmix data=mydata plots=residualpanel;&lt;BR /&gt;class group condition time;&lt;BR /&gt;model Looking= group condition time group*condition group*condition*time /dist=beta link=logit ddfm=satterthwaite solution;&lt;BR /&gt;random intercept / subject=ID type=un;&lt;BR /&gt;random intercept time / subject=ID type=un;&amp;nbsp;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;I believe that the first random intercept specify the subject variation. In the second random intercept I am not sure whether the random intercept applies variability across subjects at each level of time point. When I add the intercept of time the residuals plots show more deviations than the subject variation model only.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, the empirical = classical accounts for robust standard error?&lt;/P&gt;&lt;P&gt;Thank you for your time and help&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Dec 2024 20:24:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/953913#M47724</guid>
      <dc:creator>franSTATS</dc:creator>
      <dc:date>2024-12-17T20:24:45Z</dc:date>
    </item>
    <item>
      <title>Re: modelling intercept in proc glimmix and robust standard error</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955045#M47769</link>
      <description>&lt;P&gt;I would suggest the following code:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc glimmix data=mydata plots=residualpanel &lt;FONT color="#FF0000"&gt;method=laplace&lt;/FONT&gt;;
/* you might want to explore method=quad or method=fastquad */
class group condition time;
model Looking= group condition time group*condition group*condition*time /dist=beta link=logit &lt;FONT color="#FF0000"&gt;ddfm=kr2&lt;/FONT&gt; solution;
random intercept / subject=ID type=un;
random  time / subject=ID&lt;FONT color="#FF0000"&gt;(group*condition)&lt;/FONT&gt; type=un; 
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;So long as time is a class variable, a random intercept for only time isn't going to be meaningful, especially when there are only two levels. The GLM parameterization sets the last level to zero in the solution. I think the change in red in the last RANDOM statement will address the issue you are describing. If it doesn't, then you might consider dropping the first RANDOM statement completely and using your existing second RANDOM statement as the only one.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Other changes are to shift from the pseudo-likelihood default method to METHOD=laplace, and to use the Kenward-Roger2 method for ddfm, as it builds in a shrinkage based approach to the standard errors.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2025 17:48:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955045#M47769</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2025-01-03T17:48:40Z</dc:date>
    </item>
    <item>
      <title>Re: modelling intercept in proc glimmix and robust standard error</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955046#M47770</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15363"&gt;@SteveDenham&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;I would suggest the following code:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;proc glimmix data=mydata plots=residualpanel &lt;FONT color="#FF0000"&gt;method=laplace&lt;/FONT&gt;;
/* you might want to explore method=quad or method=fastquad */
class group condition time;
model Looking= group condition time group*condition group*condition*time /dist=beta link=logit &lt;FONT color="#FF0000"&gt;ddfm=kr2&lt;/FONT&gt; solution;
random intercept / subject=ID type=un;
random  time / subject=ID&lt;FONT color="#FF0000"&gt;(group*condition)&lt;/FONT&gt; type=un; 
run;&lt;/PRE&gt;
&lt;P&gt;(...)&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;[Just to make the red highlighting visible, which was overridden by the automatic syntax highlighting.]&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2025 18:52:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955046#M47770</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2025-01-03T18:52:29Z</dc:date>
    </item>
    <item>
      <title>Re: modelling intercept in proc glimmix and robust standard error</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955524#M47777</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/32733"&gt;@FreelanceReinh&lt;/a&gt;&amp;nbsp;!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2025 18:39:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/modelling-intercept-in-proc-glimmix-and-robust-standard-error/m-p/955524#M47777</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2025-01-08T18:39:22Z</dc:date>
    </item>
  </channel>
</rss>

