<?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: Table with AIC and AICc in Proc logistic in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/645032#M30937</link>
    <description>&lt;P&gt;UPDATE : 2021-JAN&lt;/P&gt;
&lt;P&gt;&lt;CODE class=" language-sas"&gt;&amp;nbsp;&lt;/CODE&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc logistic data= base outest=betas;
   model Yvar(event="YES")= Xvariables / selection=backward
              slentry=0.2
              slstay=0.05 details lackfit;
   ods output EffectInModel =effect;
   ods output fitstatistics=AIC( keep=Criterion InterceptAndCovariates step
        rename=(InterceptAndCovariates=AIC) where=(Criterion='AIC'));
    ods output fitstatistics= BIC (keep=Criterion InterceptAndCovariates step
        rename= (InterceptAndCovariates=BIC)  where= (Criterion='SC')); 
run;


*GET NAME VARS;
proc freq data=effect noprint;
table step*effect / out=sum1;run;
data sum1(keep=step effect count ); set sum1; run;
proc sort data=sum1; by step;run;

#VAR NAME BY STEP;
proc summary nway data=sum1 missing;
class step;
output out=new (drop=_type_ _freq_) idgroup(out[10](effect)=); run;

data want(keep= step varl); set new;
length varl $1000;
varl = catx('- ', of effect:); run;

*MERGE;
  data final(drop=criterion) ;
  merge aic bic want; by step; run;
  &lt;BR /&gt;#REPORT;&lt;BR /&gt;[...................]&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 24 Jan 2021 23:36:53 GMT</pubDate>
    <dc:creator>Mic35</dc:creator>
    <dc:date>2021-01-24T23:36:53Z</dc:date>
    <item>
      <title>Table with AIC and AICc in Proc logistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/644998#M30933</link>
      <description>&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt;Hello, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt;I try to get a &lt;/FONT&gt;&lt;SPAN class="lia-message-unread"&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt;table with AIC and AICc in Proc logistic.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt;I rode various articles and I decided to try the Qinley Huang method with %ic_logistic macro &lt;/FONT&gt;&lt;FONT size="4"&gt;&lt;SPAN&gt;(&lt;A href="https://www.pharmasug.org/proceedings/2014/SP/PharmaSUG-2014-SP04.pdf" target="_self"&gt;https://www.pharmasug.org/proceedings/2014/SP/PharmaSUG-2014-SP04.pdf)&lt;/A&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt; but I meet a problem i think due to my junior experience (to create the combiantion and model specification sheets output)&lt;/FONT&gt;.&lt;BR /&gt;&lt;BR /&gt;&lt;FONT face="arial,helvetica,sans-serif" size="4"&gt;The aim is to get this type of table :&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="lia-message-unread"&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Capture d’écran 2020-05-04 à 15.29.19.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/39034i24C31DE575B96D29/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Capture d’écran 2020-05-04 à 15.29.19.png" alt="Capture d’écran 2020-05-04 à 15.29.19.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Would you have quick tips?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="lia-message-unread"&gt;&lt;SPAN class="lia-message-unread"&gt;Thanks&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 04 May 2020 13:49:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/644998#M30933</guid>
      <dc:creator>Mic35</dc:creator>
      <dc:date>2020-05-04T13:49:22Z</dc:date>
    </item>
    <item>
      <title>Re: Table with AIC and AICc in Proc logistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/645003#M30934</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/211498"&gt;@Mic35&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;PROC LOGISTIC assigns a name to each table it creates.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can use these names to reference the table when using the ODS OUTPUT to select tables and create output data sets:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://documentation.sas.com/?docsetId=statug&amp;amp;docsetTarget=statug_logistic_details112.htm&amp;amp;docsetVersion=15.1&amp;amp;locale=en"&gt;https://documentation.sas.com/?docsetId=statug&amp;amp;docsetTarget=statug_logistic_details112.htm&amp;amp;docsetVersion=15.1&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;e.g. :&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ODS OUTPUT FitStatistics = want;

proc print data=want;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture d’écran 2020-05-04 à 16.54.15.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/39036iF1BDAFA9ECA7F2F4/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture d’écran 2020-05-04 à 16.54.15.png" alt="Capture d’écran 2020-05-04 à 16.54.15.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;</description>
      <pubDate>Mon, 04 May 2020 14:57:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/645003#M30934</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-05-04T14:57:41Z</dc:date>
    </item>
    <item>
      <title>Re: Table with AIC and AICc in Proc logistic</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/645032#M30937</link>
      <description>&lt;P&gt;UPDATE : 2021-JAN&lt;/P&gt;
&lt;P&gt;&lt;CODE class=" language-sas"&gt;&amp;nbsp;&lt;/CODE&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc logistic data= base outest=betas;
   model Yvar(event="YES")= Xvariables / selection=backward
              slentry=0.2
              slstay=0.05 details lackfit;
   ods output EffectInModel =effect;
   ods output fitstatistics=AIC( keep=Criterion InterceptAndCovariates step
        rename=(InterceptAndCovariates=AIC) where=(Criterion='AIC'));
    ods output fitstatistics= BIC (keep=Criterion InterceptAndCovariates step
        rename= (InterceptAndCovariates=BIC)  where= (Criterion='SC')); 
run;


*GET NAME VARS;
proc freq data=effect noprint;
table step*effect / out=sum1;run;
data sum1(keep=step effect count ); set sum1; run;
proc sort data=sum1; by step;run;

#VAR NAME BY STEP;
proc summary nway data=sum1 missing;
class step;
output out=new (drop=_type_ _freq_) idgroup(out[10](effect)=); run;

data want(keep= step varl); set new;
length varl $1000;
varl = catx('- ', of effect:); run;

*MERGE;
  data final(drop=criterion) ;
  merge aic bic want; by step; run;
  &lt;BR /&gt;#REPORT;&lt;BR /&gt;[...................]&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 24 Jan 2021 23:36:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Table-with-AIC-and-AICc-in-Proc-logistic/m-p/645032#M30937</guid>
      <dc:creator>Mic35</dc:creator>
      <dc:date>2021-01-24T23:36:53Z</dc:date>
    </item>
  </channel>
</rss>

