<?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: Be careful with missing values in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15833#M2831</link>
    <description>The value for a-b is ., which is less than any value.  I would expect c=2 as the only possible result.&lt;BR /&gt;
&lt;BR /&gt;
Steve Denham</description>
    <pubDate>Fri, 17 Jun 2011 11:35:12 GMT</pubDate>
    <dc:creator>SteveDenham</dc:creator>
    <dc:date>2011-06-17T11:35:12Z</dc:date>
    <item>
      <title>Be careful with missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15832#M2830</link>
      <description>The numeric value for a is 18735.&lt;BR /&gt;
&lt;BR /&gt;
data work.test;&lt;BR /&gt;
	a='18APR11'D;&lt;BR /&gt;
	b=.;&lt;BR /&gt;
	output;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
data work.test2;&lt;BR /&gt;
	set work.test;&lt;BR /&gt;
	if a-b&amp;gt;1825 then c=1;&lt;BR /&gt;
	if a-b&amp;lt;1825 then c=2;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
proc print data=work.test2;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
Result: c=2.&lt;BR /&gt;
&lt;BR /&gt;
Why c=2? It makes more sense if it is 1.</description>
      <pubDate>Fri, 17 Jun 2011 11:03:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15832#M2830</guid>
      <dc:creator>Kevin_Graduate</dc:creator>
      <dc:date>2011-06-17T11:03:46Z</dc:date>
    </item>
    <item>
      <title>Re: Be careful with missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15833#M2831</link>
      <description>The value for a-b is ., which is less than any value.  I would expect c=2 as the only possible result.&lt;BR /&gt;
&lt;BR /&gt;
Steve Denham</description>
      <pubDate>Fri, 17 Jun 2011 11:35:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15833#M2831</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2011-06-17T11:35:12Z</dc:date>
    </item>
    <item>
      <title>Re: Be careful with missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15834#M2832</link>
      <description>Hi Kevin,&lt;BR /&gt;
&lt;BR /&gt;
If you want missing values to be ignored use SAS functions instead...&lt;BR /&gt;
&lt;BR /&gt;
e.g.&lt;BR /&gt;
if sum(a,-b)&amp;gt;1825 then c=1;&lt;BR /&gt;
if sum(a,-b)&amp;lt;1825 then c=2;&lt;BR /&gt;
&lt;BR /&gt;
this will then ignore the missing value and you will get your desired c=1 as your result. &lt;BR /&gt;
&lt;BR /&gt;
This is described in the SAS documentation and in the SAS programming 1 course.&lt;BR /&gt;
&lt;BR /&gt;
Kind Regards,&lt;BR /&gt;
Michelle</description>
      <pubDate>Fri, 17 Jun 2011 12:20:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Be-careful-with-missing-values/m-p/15834#M2832</guid>
      <dc:creator>MichelleHomes</dc:creator>
      <dc:date>2011-06-17T12:20:26Z</dc:date>
    </item>
  </channel>
</rss>

