<?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: PROC MIXED Estimate statements in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732562#M35555</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You treated WEEK as a continuous variable. Then when you say weeks 1-3, do you mean the average for week 1 to week 3? That is, the average value for WEEK is 2? Similarly, weeks 4-6 means the average value for WEEK would be 5? If so, you might see if the following ESTIMATE statement does what you want:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc mixed data=data;
class id group(ref=first) ;
model y=week group group*week;
random intercept week /sub=id type=un ;
estimate "difference between weeks 1-3 and 4-6 for group 2 versus difference between weeks 1-3 and 4-6 for group 1' group*week -3 3;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 09 Apr 2021 17:18:17 GMT</pubDate>
    <dc:creator>jiltao</dc:creator>
    <dc:date>2021-04-09T17:18:17Z</dc:date>
    <item>
      <title>PROC MIXED Estimate statements</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732506#M35549</link>
      <description>&lt;P&gt;Good morning,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a longitudinal dataset with three variables: group, week, and outcome (y).&amp;nbsp;&lt;/P&gt;&lt;P&gt;Group is binary 0/1.&lt;/P&gt;&lt;P&gt;Week is continuous 1-6.&lt;/P&gt;&lt;P&gt;Outcome is continuous.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm running a mixed model, testing whether there was a significant interaction between week and group.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc mixed data=data;&lt;BR /&gt;class id group(ref=first) ;&lt;BR /&gt;model y=week group group*week;&lt;BR /&gt;random intercept week /sub=id type=un ;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would I write an estimate statement to test whether there was a significant difference in average y between weeks 1-3 and 4-6 between the two groups?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Apr 2021 14:46:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732506#M35549</guid>
      <dc:creator>lauragrau</dc:creator>
      <dc:date>2021-04-09T14:46:58Z</dc:date>
    </item>
    <item>
      <title>Re: PROC MIXED Estimate statements</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732527#M35550</link>
      <description>&lt;P&gt;Look at this wealth of info on ESTIMATE and CONTRAST statements in SAS/STAT:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The magical ESTIMATE (and CONTRAST) statements&lt;/P&gt;
&lt;P&gt;By Chris Daman on SAS Learning Post April 23, 2012&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/sastraining/2012/04/23/the-magical-estimate-and-contrast-statements/" target="_blank"&gt;https://blogs.sas.com/content/sastraining/2012/04/23/the-magical-estimate-and-contrast-statements/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"Easy button" for ESTIMATE statements&lt;/P&gt;
&lt;P&gt;By Chris Daman on SAS Learning Post April 25, 2012&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/sastraining/2012/04/25/easy-button-for-estimate-statements/" target="_blank"&gt;https://blogs.sas.com/content/sastraining/2012/04/25/easy-button-for-estimate-statements/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ESTIMATE Statements - the final installment&lt;/P&gt;
&lt;P&gt;By Chris Daman on SAS Learning Post May 2, 2012&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/sastraining/2012/05/02/estimate-statements-the-final-installment/" target="_blank"&gt;https://blogs.sas.com/content/sastraining/2012/05/02/estimate-statements-the-final-installment/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How to write CONTRAST and ESTIMATE statements in SAS regression procedures?&lt;/P&gt;
&lt;P&gt;By Rick Wicklin on The DO Loop June 6, 2016&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/iml/2016/06/06/write-contrast-estimate-statements-sas-regression-procedures.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2016/06/06/write-contrast-estimate-statements-sas-regression-procedures.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Usage Note 24447: Examples of writing CONTRAST and ESTIMATE statements&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/kb/24/447.html" target="_blank"&gt;https://support.sas.com/kb/24/447.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Usage Note 67024: Using the ESTIMATE or CONTRAST statement or Margins macro to assess continuous variable effects in interactions and splines&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/kb/67/024.html" target="_blank"&gt;67024 - Using the ESTIMATE or CONTRAST statement or Margins macro to assess continuous variable effects in interactions and splines (sas.com)&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good luck,&lt;/P&gt;
&lt;P&gt;Koen&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Apr 2021 15:36:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732527#M35550</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2021-04-09T15:36:27Z</dc:date>
    </item>
    <item>
      <title>Re: PROC MIXED Estimate statements</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732562#M35555</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You treated WEEK as a continuous variable. Then when you say weeks 1-3, do you mean the average for week 1 to week 3? That is, the average value for WEEK is 2? Similarly, weeks 4-6 means the average value for WEEK would be 5? If so, you might see if the following ESTIMATE statement does what you want:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc mixed data=data;
class id group(ref=first) ;
model y=week group group*week;
random intercept week /sub=id type=un ;
estimate "difference between weeks 1-3 and 4-6 for group 2 versus difference between weeks 1-3 and 4-6 for group 1' group*week -3 3;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 09 Apr 2021 17:18:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/PROC-MIXED-Estimate-statements/m-p/732562#M35555</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-04-09T17:18:17Z</dc:date>
    </item>
  </channel>
</rss>

