<?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: Get statistics (AIC's) of all models of a stepwise regression in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253415#M13375</link>
    <description>&lt;P&gt;You&amp;nbsp; shouldn't be using stepwise to build models - the results are wrong see e.g. &lt;A href="http://www.lexjansen.com/pnwsug/2008/DavidCassell-StoppingStepwise.pdf" target="_self"&gt;Stopping Stepwise&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, if you still want this, you can use GLMSELECT and use the DETAILS = FITSTATISTICS on the MODEL statement.&lt;/P&gt;</description>
    <pubDate>Tue, 01 Mar 2016 12:22:00 GMT</pubDate>
    <dc:creator>plf515</dc:creator>
    <dc:date>2016-03-01T12:22:00Z</dc:date>
    <item>
      <title>Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253392#M13371</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How can I get the AIC's of all models of stepwise regression? If I use this code, I only get the result for the final model:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;Data&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Input (&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Drop&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=i j);&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Array&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; X{*} X1-X500;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Do&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; j=&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;To&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;140&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; X1=Rannor(&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;);&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; X2=Rannor(&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;);&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; Y=&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;2&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;+X1*&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;3&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;-X2*&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;4&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;+Rannor(&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;)-&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0.5&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Do&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; i=&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;3&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;To&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;500&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; X{i}=Rannor(&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;); &lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;End&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Output&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;End&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;Run&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;Proc&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;Reg&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Data&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;=Input &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;OutEst&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;=Result;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Model&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; Y = X1-X500 / Selection=Forward &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AIC&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;BIC&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;Run&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks &amp;amp; kind regards&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2016 11:19:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253392#M13371</guid>
      <dc:creator>user24feb</dc:creator>
      <dc:date>2016-03-01T11:19:46Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253404#M13372</link>
      <description>&lt;P&gt;You can try use PROC HPGENSELECT.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
proc hpgenselect data=input;
Model Y = X1-X50/dist=normal link=id;
Selection method=forward(choose=aic);
Run;
  &lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;It shows the AIC value from each model. It also choose the model based on the AIC. Unfortunately I&amp;nbsp;couldn't get it to work with 500 variables (error message due to resource problems) so I only included the first 50 variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Effect Number p&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Step Entered Effects In AIC Value&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;0 Intercept 1 877.2496 .&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;------------------------------------------------------------&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;1&amp;nbsp;&amp;nbsp; x2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2&amp;nbsp; &amp;nbsp;760.4677 &amp;lt;.0001&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;2&amp;nbsp;&amp;nbsp; x1&amp;nbsp;&amp;nbsp;&amp;nbsp; 3&amp;nbsp; &amp;nbsp;413.6365 &amp;lt;.0001&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;3&amp;nbsp; &amp;nbsp;x39&amp;nbsp; &amp;nbsp;4&amp;nbsp;&amp;nbsp; 406.7601 0.0034&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;4&amp;nbsp;&amp;nbsp; x47&amp;nbsp; &amp;nbsp;5&amp;nbsp;&amp;nbsp; 400.3529 0.0043&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;5&amp;nbsp;&amp;nbsp; x17&amp;nbsp; &amp;nbsp;6&amp;nbsp;&amp;nbsp; 395.3228* 0.0088&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2016 11:49:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253404#M13372</guid>
      <dc:creator>JacobSimonsen</dc:creator>
      <dc:date>2016-03-01T11:49:50Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253412#M13373</link>
      <description>I'm sorry for the typos in my code. If I copy-paste something (I think including squiggly brackets), the editor kind of "self-destructs".</description>
      <pubDate>Tue, 01 Mar 2016 12:11:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253412#M13373</guid>
      <dc:creator>user24feb</dc:creator>
      <dc:date>2016-03-01T12:11:08Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253414#M13374</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods output SelParmEst=SelParmEst;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 01 Mar 2016 12:20:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253414#M13374</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-03-01T12:20:20Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253415#M13375</link>
      <description>&lt;P&gt;You&amp;nbsp; shouldn't be using stepwise to build models - the results are wrong see e.g. &lt;A href="http://www.lexjansen.com/pnwsug/2008/DavidCassell-StoppingStepwise.pdf" target="_self"&gt;Stopping Stepwise&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, if you still want this, you can use GLMSELECT and use the DETAILS = FITSTATISTICS on the MODEL statement.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2016 12:22:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253415#M13375</guid>
      <dc:creator>plf515</dc:creator>
      <dc:date>2016-03-01T12:22:00Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253416#M13376</link>
      <description>&lt;P&gt;Here's sample code for&amp;nbsp;PROC GLMSELECT:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc glmselect data=input;
model y = x1-x5 / selection=forward(select=sl) stats=bic details=all;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;The sub-option SELECT=SL specifies that variable&amp;nbsp;selection is based on the significance level of the F statistic (similar to PROC REG, the default would be different: SBC). Option STATS=BIC includes the BIC in the output. AIC is included by default. DETAILS=ALL requests fit statistics and many other details about the models at each step of the variable selection process.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've reduced the number of independent variables to 5 just for demonstration. Having&amp;nbsp;more explanatory effects (500) than observations (140) in the analysis dataset would not be sensible for the general linear model anyway.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2016 12:34:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253416#M13376</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2016-03-01T12:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Get statistics (AIC's) of all models of a stepwise regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253427#M13378</link>
      <description>&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15128"&gt;@plf515&lt;/a&gt;&lt;BR /&gt; I agree partly ...and also disagree partly...&lt;BR /&gt;Stepwise method have tendency to include too many variables. But, if it is clear when the results is reported that the associations was found by model section and not by testing well defined hypthoses, then there is no problem. Or, if the variable selection is done on a training dataset to generate hypothis, which then is tested on an other dataset it is also a valid approach.</description>
      <pubDate>Tue, 01 Mar 2016 13:30:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Get-statistics-AIC-s-of-all-models-of-a-stepwise-regression/m-p/253427#M13378</guid>
      <dc:creator>JacobSimonsen</dc:creator>
      <dc:date>2016-03-01T13:30:24Z</dc:date>
    </item>
  </channel>
</rss>

