<?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 proc stdize errors in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56352#M2597</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great. I think I will try both the methods. Thank you for your suggestions, Art.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 29 Aug 2011 17:16:44 GMT</pubDate>
    <dc:creator>saspert</dc:creator>
    <dc:date>2011-08-29T17:16:44Z</dc:date>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56346#M2591</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am using Proc STDIZE for a very mundane task of identifying all numeric variables and converting their missing values to 0. However it is giving an error when there is lack of data. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The original code is here -&lt;/P&gt;&lt;P&gt;%MACRO _CONVERT_MV_TO_ZERO(DATASET);&lt;/P&gt;&lt;P&gt;PROC STDIZE DATA=&amp;amp;DATASET OUT=&amp;amp;DATASET REPONLY MISSING=0;&lt;/P&gt;&lt;P&gt;VAR _NUMERIC_;&lt;/P&gt;&lt;P&gt;RUN;&lt;/P&gt;&lt;P&gt;%MEND _CONVERT_MV_TO_ZERO;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And the log file is here -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SYMBOLGEN:&amp;nbsp; Macro variable DATASET resolves to SEG_TOT_COMP_PGM_TR&lt;BR /&gt;SYMBOLGEN:&amp;nbsp; Macro variable DATASET resolves to SEG_TOT_COMP_PGM_TR&lt;BR /&gt;MPRINT(_CONVERT_MV_TO_ZERO):&amp;nbsp;&amp;nbsp; PROC STDIZE DATA=SEG_TOT_COMP_PGM_TR OUT=SEG_TOT_COMP_PGM_TR REPONLY MISSING=0;&lt;BR /&gt;MPRINT(_CONVERT_MV_TO_ZERO):&amp;nbsp;&amp;nbsp; VAR _NUMERIC_;&lt;BR /&gt;WARNING: No numeric variables found in data set WORK.SEG_TOT_COMP_PGM_TR.&lt;BR /&gt;MPRINT(_CONVERT_MV_TO_ZERO):&amp;nbsp;&amp;nbsp; RUN;&lt;/P&gt;&lt;P&gt;ERROR: No variables to analyze.&lt;BR /&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;BR /&gt;NOTE: SAS set option OBS=0 and will continue to check statements. This may cause NOTE: No observations in data set.&lt;BR /&gt;WARNING: The data set WORK.SEG_TOT_COMP_PGM_TR may be incomplete.&amp;nbsp; When this step was stopped there were 0 observations and 0 variables.&lt;BR /&gt;WARNING: Data set WORK.SEG_TOT_COMP_PGM_TR was not replaced because this step was stopped.&lt;BR /&gt;NOTE: PROCEDURE STDIZE used (Total process time):&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; user cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; system cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Memory&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 25k&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Page Faults&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Page Reclaims&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Page Swaps&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Voluntary Context Switches&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Involuntary Context Switches&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Block Input Operations&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Block Output Operations&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;Is there an option to ignore or bypass the 'No variables to analyze' error? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;saspert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 14:27:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56346#M2591</guid>
      <dc:creator>saspert</dc:creator>
      <dc:date>2011-08-29T14:27:03Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56347#M2592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Couldn't you just change your macro so that it first checks to see if there are any numeric fields?&amp;nbsp; e.g.:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%MACRO _CONVERT_MV_TO_ZERO(DATASET);&lt;/P&gt;&lt;P&gt;&amp;nbsp; proc sql noprint;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; select count(*) into :nums&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; from dictionary.columns&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where libname="WORK"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; and memname=upcase("&amp;amp;DATASET."&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; and type="num"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; %if &amp;amp;nums. gt 0 %then %do;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PROC STDIZE DATA=&amp;amp;DATASET OUT=&amp;amp;DATASET REPONLY MISSING=0;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; VAR _NUMERIC_;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; RUN;&lt;/P&gt;&lt;P&gt;&amp;nbsp; %end;&lt;/P&gt;&lt;P&gt;%MEND _CONVERT_MV_TO_ZERO;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 14:57:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56347#M2592</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-29T14:57:56Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56348#M2593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Thanks Art. I was looking for a hint on those lines. But do you know if there is a better way to change the missing values to zero itself. I mean if I can change the way the macro _convert_mv_to_zero works - instead of using PROC STDIZE. &lt;/P&gt;&lt;P&gt;&lt;BR /&gt;The reason I am asking it because I am not 100% familiar with that procedure and I do get several warnings like these too -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;WARNING: The scale estimator for variable SEG_BIO_SCREEN0 is less than or equal to 0. SEG_BIO_SCREEN0 will not be standardized.&lt;/P&gt;&lt;P&gt;WARNING: The scale estimator for variable SEG_BIO_SCREEN1 is less than or equal to 0. SEG_BIO_SCREEN1 will not be standardized.&lt;/P&gt;&lt;P&gt;WARNING: A missing value is assigned to the scale estimator for variable SEG_BIO_SCREEN0 because its scale estimator is less than &lt;/P&gt;&lt;P&gt;or equal to 0 before fuzzing.&lt;/P&gt;&lt;P&gt;WARNING: A missing value is assigned to the scale estimator for variable SEG_BIO_SCREEN1 because its scale estimator is less than &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or equal to 0 before fuzzing.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;﻿I will try your option. But if there is a better way to convert all the missing values in all the numeric fields, I would want to try that.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/SPAN&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/SPAN&gt;saspert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 15:13:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56348#M2593</guid>
      <dc:creator>saspert</dc:creator>
      <dc:date>2011-08-29T15:13:39Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56349#M2594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is always the SAS suggested method: &lt;A href="http://support.sas.com/kb/24/693.html"&gt;http://support.sas.com/kb/24/693.html&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 15:17:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56349#M2594</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-29T15:17:10Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56350#M2595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Defining an ARRAY _NUMERIC_ will produce an ERROR similar to PROC STDIZE when there are no numeric variables.&amp;nbsp; I think checking using dictionary.columns or similar is good plus if there are no missing values the is no need to process further.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 15:48:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56350#M2595</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2011-08-29T15:48:22Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56351#M2596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You are going to have to define "better" better.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PROC STDIZE is simple to code, quick enough for most and it is obvious what is being done REPONLY MISSING=0.&amp;nbsp; What could be simpler?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Perhaps you can address the missing to zeros problem proactively rather than reactively.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA=SEG_TOT_COMP_PGM_TR: this data name suggest to me it is some type of TRansposed TOTal COMPuted in the ProGraM.&amp;nbsp; Do you know about PRELOADFMT and or CLASSDATA=?&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 15:59:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56351#M2596</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2011-08-29T15:59:38Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56352#M2597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great. I think I will try both the methods. Thank you for your suggestions, Art.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 17:16:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56352#M2597</guid>
      <dc:creator>saspert</dc:creator>
      <dc:date>2011-08-29T17:16:44Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56353#M2598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is very strange, I run your code under my SAS9.2, It is OK, there is no ERROR or WARNING.&lt;/P&gt;&lt;P&gt;Here is another solution by using data step.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;data temp;
 set sashelp.class;
 if _n_ in (2 4 6 8 ) then call missing(weight,height);
run;
%global list;
proc sql noprint;
 select name||'=coalesce('||name||',0);'
&amp;nbsp; into : list separated by ' '
&amp;nbsp;&amp;nbsp; from dictionary.columns
&amp;nbsp;&amp;nbsp;&amp;nbsp; where libname='WORK' and memname='TEMP' and type='num';
quit;
data want;
 set temp;
 &amp;amp;list
run;

&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ksharp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 30 Aug 2011 03:53:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56353#M2598</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-08-30T03:53:00Z</dc:date>
    </item>
    <item>
      <title>proc stdize errors</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56354#M2599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Hi Data _null_,&lt;/P&gt;&lt;P&gt;Thank you for pointing out the flaw with using the SAS alternative. I think I will just stick with the original code + Art's macro check on the variables. When I say "better", I meant a more familiar routine. I am not that familiar with statistical procedures. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;saspert.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 21:16:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/proc-stdize-errors/m-p/56354#M2599</guid>
      <dc:creator>saspert</dc:creator>
      <dc:date>2011-08-31T21:16:24Z</dc:date>
    </item>
  </channel>
</rss>

