<?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 HPGENSELECT: How to score the original dataset / append Predicted Values and Residuals in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/PROC-HPGENSELECT-How-to-score-the-original-dataset-append/m-p/834221#M82050</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Two possibilities here :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1. Use an ID statement and then merge with original data. &lt;BR /&gt;The ID is the identifier for the observation.&lt;BR /&gt;PROC HPGENSELECT -- OUTPUT statement :&lt;/P&gt;
&lt;DIV class="xisDoc-refProc"&gt;
&lt;DIV id="stathpug.hpgenselect.output_stmt" class="aa-section"&gt;
&lt;P class="xisDoc-paragraph"&gt;The variables in the input data set are &lt;STRONG&gt;not&lt;/STRONG&gt; included in the output data set to avoid data duplication for large data sets; &lt;STRONG&gt;however, variables that are specified in the ID statement are included.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;2. Use the CODE statement :&lt;/P&gt;
&lt;DIV class="xisDoc-refProc"&gt;
&lt;DIV id="stathpug.hpgenselect.lmrstmtcode" class="aa-section"&gt;
&lt;P class="xisDoc-paragraph"&gt;The CODE statement writes SAS DATA step code for computing predicted values of the fitted model either to a file or to a catalog entry. This code can then be included in a DATA step to score new data.&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Use this score code to score your original data ! Original explanatory variables will be kept.&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Kind regards,&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Koen&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
    <pubDate>Tue, 20 Sep 2022 07:16:30 GMT</pubDate>
    <dc:creator>sbxkoenk</dc:creator>
    <dc:date>2022-09-20T07:16:30Z</dc:date>
    <item>
      <title>PROC HPGENSELECT: How to score the original dataset / append Predicted Values and Residuals</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/PROC-HPGENSELECT-How-to-score-the-original-dataset-append/m-p/834217#M82049</link>
      <description>&lt;P&gt;In PROC HPGENSELECT, how to score the original dataset / append predicted values and residuals to the right? For example, the code below would produce OutDsn with only 2 columns (Pred1 and Resid1). And I'd like OutDsn = InDsn + 2 columns appended to the right of it? Thanks for the insights!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;PROC HPGENSELECT data=inDsn FCONV=1E-8 MAXITER=500 ITSUMMARY;
CLASS Credit(ref = "A1") ;
MODEL Loss = Credit / dist= Gamma link=log;
WEIGHT ECD;
OUTPUT out=outDsn Predicted = Pred1 Residual = Resid1 ;
ODS OUTPUT ParameterEstimates= PEs;
RUN;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Sep 2022 06:05:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/PROC-HPGENSELECT-How-to-score-the-original-dataset-append/m-p/834217#M82049</guid>
      <dc:creator>Bear85</dc:creator>
      <dc:date>2022-09-20T06:05:36Z</dc:date>
    </item>
    <item>
      <title>Re: PROC HPGENSELECT: How to score the original dataset / append Predicted Values and Residuals</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/PROC-HPGENSELECT-How-to-score-the-original-dataset-append/m-p/834221#M82050</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Two possibilities here :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1. Use an ID statement and then merge with original data. &lt;BR /&gt;The ID is the identifier for the observation.&lt;BR /&gt;PROC HPGENSELECT -- OUTPUT statement :&lt;/P&gt;
&lt;DIV class="xisDoc-refProc"&gt;
&lt;DIV id="stathpug.hpgenselect.output_stmt" class="aa-section"&gt;
&lt;P class="xisDoc-paragraph"&gt;The variables in the input data set are &lt;STRONG&gt;not&lt;/STRONG&gt; included in the output data set to avoid data duplication for large data sets; &lt;STRONG&gt;however, variables that are specified in the ID statement are included.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;2. Use the CODE statement :&lt;/P&gt;
&lt;DIV class="xisDoc-refProc"&gt;
&lt;DIV id="stathpug.hpgenselect.lmrstmtcode" class="aa-section"&gt;
&lt;P class="xisDoc-paragraph"&gt;The CODE statement writes SAS DATA step code for computing predicted values of the fitted model either to a file or to a catalog entry. This code can then be included in a DATA step to score new data.&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Use this score code to score your original data ! Original explanatory variables will be kept.&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Kind regards,&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;Koen&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Tue, 20 Sep 2022 07:16:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/PROC-HPGENSELECT-How-to-score-the-original-dataset-append/m-p/834221#M82050</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2022-09-20T07:16:30Z</dc:date>
    </item>
  </channel>
</rss>

