<?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 F Test of Interaction Terms in Proc Surveylogistic in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728773#M35583</link>
    <description>&lt;P&gt;Hi.&amp;nbsp; I am conducting a difference in differences analysis of a policy. I intend to check whether there is a parallel trend for an intervention site and a comparison site. Since the outcome variable is binary at individual level, I've run a regression in surveylogistic procedure. The model is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Outcome&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt;=Intervention + Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; + Intervention * Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; + &lt;STRONG&gt;x&lt;/STRONG&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt; + ϵ&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Outcome is a dummy variable. Intervention is a dummy variable with 1 for the intervention site and 0 for the comparison site. Month is a categorical variable (not continuous) for the period before the policy got effective. Intervention * Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; is the interactions between Intervention and Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; (i.e. since Month is categorical, there are multiple interaction terms ). &lt;STRONG&gt;X &lt;/STRONG&gt;is a vector of individual characteristics, and ϵ is the error term.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To test whether the two sites have parallel trend, I need to perform a F-test on the coefficients of all interaction terms jointly. The issue is when I used the code “test1: test Intervention * Month;” after the line of code for Model, I got an error message. However, I could use the same line of test code for coefficients of other independent variables in the model such as Month (i.e. “test1: test Month;”). Can anyone suggest how I can perform a F-test for all interaction terms jointly in SAS?&amp;nbsp; Thanks.&lt;/P&gt;</description>
    <pubDate>Wed, 24 Mar 2021 15:18:06 GMT</pubDate>
    <dc:creator>SAS41</dc:creator>
    <dc:date>2021-03-24T15:18:06Z</dc:date>
    <item>
      <title>F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728773#M35583</link>
      <description>&lt;P&gt;Hi.&amp;nbsp; I am conducting a difference in differences analysis of a policy. I intend to check whether there is a parallel trend for an intervention site and a comparison site. Since the outcome variable is binary at individual level, I've run a regression in surveylogistic procedure. The model is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Outcome&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt;=Intervention + Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; + Intervention * Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; + &lt;STRONG&gt;x&lt;/STRONG&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt; + ϵ&lt;FONT size="1 2 3 4 5 6 7"&gt;it&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Outcome is a dummy variable. Intervention is a dummy variable with 1 for the intervention site and 0 for the comparison site. Month is a categorical variable (not continuous) for the period before the policy got effective. Intervention * Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; is the interactions between Intervention and Month&lt;FONT size="1 2 3 4 5 6 7"&gt;t&lt;/FONT&gt; (i.e. since Month is categorical, there are multiple interaction terms ). &lt;STRONG&gt;X &lt;/STRONG&gt;is a vector of individual characteristics, and ϵ is the error term.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To test whether the two sites have parallel trend, I need to perform a F-test on the coefficients of all interaction terms jointly. The issue is when I used the code “test1: test Intervention * Month;” after the line of code for Model, I got an error message. However, I could use the same line of test code for coefficients of other independent variables in the model such as Month (i.e. “test1: test Month;”). Can anyone suggest how I can perform a F-test for all interaction terms jointly in SAS?&amp;nbsp; Thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Mar 2021 15:18:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728773#M35583</guid>
      <dc:creator>SAS41</dc:creator>
      <dc:date>2021-03-24T15:18:06Z</dc:date>
    </item>
    <item>
      <title>Re: F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728784#M35584</link>
      <description>&lt;P&gt;Show us the log for PROC SURVEYLOGISTIC, the entire log for PROC SURVEYLOGISTIC, with nothing chopped out, from the PROC SURVEYLOGISTIC statement all the way down to the last NOTE after PROC SURVEYLOGISTIC.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please format the log for easy readability, by copying the log as text and pasting it into the window that appears when you click on the &amp;lt;/&amp;gt; icon.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Mar 2021 15:40:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728784#M35584</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-03-24T15:40:44Z</dc:date>
    </item>
    <item>
      <title>Re: F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728790#M35585</link>
      <description>&lt;P&gt;Adding just a bit to &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt;'s comment:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best practice on this forum for &lt;STRONG&gt;any&lt;/STRONG&gt; question regarding any error, warning or note from the log is to copy from the log the entire procedure or data step code and all the messages for that block of code and paste into a text box opened with the &amp;lt;/&amp;gt; icon.&lt;/P&gt;
&lt;P&gt;The text box preserves formatting of text when SAS supplies diagnostic indicators which can get shifted by the main message windows. Plus the appearance of the block offsets the code from the discussion text visually. Pasting as text is also important as often we can provide code corrections or highlights by copy/edit/paste that just are not possible with images.&lt;/P&gt;
&lt;P&gt;The entire block of code is needed because in many procedures some options require other options to be set. Or the proverbial "missing semicolon" failing to end a previous code statement lines above the reported error may be the cause.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also we want the code from the log as that shows exactly what was submitted. It is amazing just how often we see a question about "I ran this code and xxxx did/ did not happen" where the "code" pasted will not run or cannot possibly generate the described behavior because no variable or option of the type is used in the code that an error reports.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Mar 2021 15:50:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728790#M35585</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-03-24T15:50:43Z</dc:date>
    </item>
    <item>
      <title>Re: F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728863#M35586</link>
      <description>&lt;P&gt;Thank both of your for your feedback. This following is a part of the log to illustrate the issue. Basically, I want to do a F-test of all interaction terms jointly for the parallel trend assumption.&lt;/P&gt;&lt;PRE&gt;629  proc surveylogistic data=data;
NOTE: PROCEDURE SURVEYLOGISTIC used (Total process time):
      real time           0.00 seconds
      cpu time            0.00 seconds

NOTE: The SAS System stopped processing this step because of errors.
630  class intervention month agegroup ;
631  model outcome= intervention month intervention*month agegroup / DF=INFINITY ridging=absolute
631! ;
632  test1: test month1=month2;
633  test2: test month1=month2=month3=0;
634  test3: test intervention*month1=intervention*month2;
                             -
                             22
                             76
ERROR 22-322: Syntax error, expecting one of the following: ;, +, ',', -, /, =, {.
ERROR 76-322: Syntax error, statement will be ignored.
635  run;


&lt;/PRE&gt;</description>
      <pubDate>Wed, 24 Mar 2021 19:36:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728863#M35586</guid>
      <dc:creator>SAS41</dc:creator>
      <dc:date>2021-03-24T19:36:56Z</dc:date>
    </item>
    <item>
      <title>Re: F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728871#M35587</link>
      <description>&lt;P&gt;Please read the documentation on the SLICE statement:&amp;nbsp;&lt;A href="https://documentation.sas.com/?cdcId=pgmsascdc&amp;amp;cdcVersion=9.4_3.4&amp;amp;docsetId=statug&amp;amp;docsetTarget=statug_introcom_sect064.htm&amp;amp;locale=en"&gt;https://documentation.sas.com/?cdcId=pgmsascdc&amp;amp;cdcVersion=9.4_3.4&amp;amp;docsetId=statug&amp;amp;docsetTarget=statug_introcom_sect064.htm&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Mar 2021 19:52:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/728871#M35587</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-03-24T19:52:37Z</dc:date>
    </item>
    <item>
      <title>Re: F Test of Interaction Terms in Proc Surveylogistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/733269#M35588</link>
      <description>&lt;P&gt;It sounds like all you really want is the Type3 test for the interaction which should be part of the default output when you run:&lt;/P&gt;
&lt;P&gt;proc surveylogistic;&lt;/P&gt;
&lt;P&gt;class intervention month/param=glm;&lt;/P&gt;
&lt;P&gt;model reponse=intervention|month;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 11:14:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/F-Test-of-Interaction-Terms-in-Proc-Surveylogistic/m-p/733269#M35588</guid>
      <dc:creator>SAS_Rob</dc:creator>
      <dc:date>2021-04-13T11:14:32Z</dc:date>
    </item>
  </channel>
</rss>

