<?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 Stepwise Regression, HOW to tell 2-Step regression or just 1-Step regession?! in SAS Forecasting and Econometrics</title>
    <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833758#M4506</link>
    <description>&lt;P&gt;The link below give out Stepwise Regression.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/SAS-Programming/How-to-do-Regression-on-Broken-Turning-Line/m-p/832265#M328943" target="_self"&gt;https://communities.sas.com/t5/SAS-Programming/How-to-do-Regression-on-Broken-Turning-Line/m-p/832265#M328943&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have one quest. Say I have dataset below. Surely I can have code on two-step regression. But how to tell(what criteria to tell) two-step&lt;/P&gt;
&lt;P&gt;is better than one-step regression?! Thanks,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let slope1=-2; %let slope2=5; %let turner=90;

data indata;
do i=1 to 100;
	if i&amp;lt;&amp;amp;turner. then y=5*ranuni(i)+i*&amp;amp;slope1.;
	else y=10*ranuni(i)+i*&amp;amp;slope2.-&amp;amp;turner.*&amp;amp;slope2.+&amp;amp;turner.*&amp;amp;slope1.;
	output;
end;
run;quit;

ods listing gpath="%sysfunc(getoption(work))";
proc sgplot data=indata;
scatter x=i y=y; 
run;quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SGPlot29.png" style="width: 640px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/75303i972BC2E7832EA69F/image-size/large?v=v2&amp;amp;px=999" role="button" title="SGPlot29.png" alt="SGPlot29.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 16 Sep 2022 02:16:45 GMT</pubDate>
    <dc:creator>hellohere</dc:creator>
    <dc:date>2022-09-16T02:16:45Z</dc:date>
    <item>
      <title>Stepwise Regression, HOW to tell 2-Step regression or just 1-Step regession?!</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833758#M4506</link>
      <description>&lt;P&gt;The link below give out Stepwise Regression.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/SAS-Programming/How-to-do-Regression-on-Broken-Turning-Line/m-p/832265#M328943" target="_self"&gt;https://communities.sas.com/t5/SAS-Programming/How-to-do-Regression-on-Broken-Turning-Line/m-p/832265#M328943&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have one quest. Say I have dataset below. Surely I can have code on two-step regression. But how to tell(what criteria to tell) two-step&lt;/P&gt;
&lt;P&gt;is better than one-step regression?! Thanks,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let slope1=-2; %let slope2=5; %let turner=90;

data indata;
do i=1 to 100;
	if i&amp;lt;&amp;amp;turner. then y=5*ranuni(i)+i*&amp;amp;slope1.;
	else y=10*ranuni(i)+i*&amp;amp;slope2.-&amp;amp;turner.*&amp;amp;slope2.+&amp;amp;turner.*&amp;amp;slope1.;
	output;
end;
run;quit;

ods listing gpath="%sysfunc(getoption(work))";
proc sgplot data=indata;
scatter x=i y=y; 
run;quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SGPlot29.png" style="width: 640px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/75303i972BC2E7832EA69F/image-size/large?v=v2&amp;amp;px=999" role="button" title="SGPlot29.png" alt="SGPlot29.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 02:16:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833758#M4506</guid>
      <dc:creator>hellohere</dc:creator>
      <dc:date>2022-09-16T02:16:45Z</dc:date>
    </item>
    <item>
      <title>Re: Stepwise Regression, HOW to tell 2-Step regression or just 1-Step regession?!</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833760#M4507</link>
      <description>&lt;P&gt;The dataset is hypo. What if turner=95 or turner=98?!&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 02:17:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833760#M4507</guid>
      <dc:creator>hellohere</dc:creator>
      <dc:date>2022-09-16T02:17:44Z</dc:date>
    </item>
    <item>
      <title>Re: Stepwise Regression, HOW to tell 2-Step regression or just 1-Step regession?!</title>
      <link>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833797#M4508</link>
      <description>&lt;P data-unlink="true"&gt;Duplicate post. An answer was discussed &lt;A href="https://communities.sas.com/t5/SAS-Programming/How-to-do-Regression-on-Broken-Turning-Line/m-p/833785#M329633" target="_self"&gt;here&lt;/A&gt;. Please put all discussion of this problem in one location, at the link I gave.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 10:11:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Forecasting-and-Econometrics/Stepwise-Regression-HOW-to-tell-2-Step-regression-or-just-1-Step/m-p/833797#M4508</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2022-09-16T10:11:15Z</dc:date>
    </item>
  </channel>
</rss>

