<?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: Set numeric missing value as 'NA' in SAS Data Management</title>
    <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/315015#M9017</link>
    <description>&lt;P&gt;The NUMERIC variables of your array ZERO are still numeric.&lt;/P&gt;
&lt;P&gt;zero [i] = 'NA' will fail as 'NA' isn't acceptable. And that is what you are doing with the PUT statement.&lt;/P&gt;
&lt;P&gt;try&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data test;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; set output_de21_de42;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; format &amp;nbsp;_numeric_ &amp;nbsp;trouble.;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
    <pubDate>Tue, 29 Nov 2016 00:03:11 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2016-11-29T00:03:11Z</dc:date>
    <item>
      <title>Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314900#M9011</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hey there, as the title says,&amp;nbsp;how can I make&amp;nbsp;the numberic missing value (format: BEST12., informat: 12.) showed as&amp;nbsp;'NA' in below data set?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I tried to use put() statement to transform numeric variables to character first, but the transformation doesn't work.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/6050i1AC112C1C498342D/image-size/original?v=v2&amp;amp;px=-1" border="0" alt="qq.PNG" title="qq.PNG" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Nov 2016 17:41:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314900#M9011</guid>
      <dc:creator>zhouxysherry</dc:creator>
      <dc:date>2016-11-28T17:41:27Z</dc:date>
    </item>
    <item>
      <title>Re: Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314951#M9013</link>
      <description>There's not enough detail in your post to determine exactly what you are trying to do and where you want 'NA' to show up: data view, report, some sort of procedure output?&lt;BR /&gt;&lt;BR /&gt;Try to apply a format:&lt;BR /&gt;PROC FORMAT; value NA .='NA'; run;</description>
      <pubDate>Mon, 28 Nov 2016 20:31:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314951#M9013</guid>
      <dc:creator>Haris</dc:creator>
      <dc:date>2016-11-28T20:31:37Z</dc:date>
    </item>
    <item>
      <title>Re: Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314980#M9014</link>
      <description>&lt;P&gt;I would like 'NA' to show in data view.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried PROC FORMAT, but it doesn't work.&lt;/P&gt;&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/6054i961528D047489EB5/image-size/original?v=v2&amp;amp;px=-1" border="0" alt="error.PNG" title="error.PNG" width="671" height="312" /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Nov 2016 21:56:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314980#M9014</guid>
      <dc:creator>zhouxysherry</dc:creator>
      <dc:date>2016-11-28T21:56:14Z</dc:date>
    </item>
    <item>
      <title>Re: Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314988#M9015</link>
      <description>&lt;P&gt;You need to assign the format to your variables too. &amp;nbsp;This code works for me. &amp;nbsp;You may also need to tell your data viewer what to display: different machines have different defaults and can either show raw or formatted values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format; value NA .='NA'; run;

data test;
	a = .; b=1; c=1; output;
	a = 1; b=.; c=1; output;
	a = 1; b=1; c=.; output;
	format a b c NA.;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 28 Nov 2016 22:20:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/314988#M9015</guid>
      <dc:creator>Haris</dc:creator>
      <dc:date>2016-11-28T22:20:01Z</dc:date>
    </item>
    <item>
      <title>Re: Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/315015#M9017</link>
      <description>&lt;P&gt;The NUMERIC variables of your array ZERO are still numeric.&lt;/P&gt;
&lt;P&gt;zero [i] = 'NA' will fail as 'NA' isn't acceptable. And that is what you are doing with the PUT statement.&lt;/P&gt;
&lt;P&gt;try&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data test;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; set output_de21_de42;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; format &amp;nbsp;_numeric_ &amp;nbsp;trouble.;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 00:03:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/315015#M9017</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-11-29T00:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: Set numeric missing value as 'NA'</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/316297#M9070</link>
      <description>&lt;P&gt;Change the variable(s) to a characters&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Use a case statement to apply the NA values in the transformation otherwise that value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It may be more appropriate to transpose the dataset before applying as this will mean less cols to change.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Dec 2016 16:53:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Set-numeric-missing-value-as-NA/m-p/316297#M9070</guid>
      <dc:creator>David_Luttrell</dc:creator>
      <dc:date>2016-12-02T16:53:00Z</dc:date>
    </item>
  </channel>
</rss>

