<?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: How to compute a variabel as the sum of other variables and ignore missing values in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/559040#M74837</link>
    <description>&lt;P&gt;And if you have actual variable names that are not as nice just list them in the sum function:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Psum = sum (thisvar, thatvar, somethingelse, othervar, varx);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you are interested most of the basic statistics are available using similar syntax: N Mean Min Max Range STD Var (variance) Skewness and others.&lt;/P&gt;</description>
    <pubDate>Wed, 15 May 2019 16:08:01 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2019-05-15T16:08:01Z</dc:date>
    <item>
      <title>How to compute a variabel as the sum of other variables and ignore missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/558976#M74825</link>
      <description>&lt;P&gt;I want to compute a new numeric variabel, "Psum", as the sum of 5 other numeric variable, P1, p2, p3, p4, p5. A simpel way to do it could be:&amp;nbsp;&lt;/P&gt;&lt;P&gt;Psum= p1+p2+p3+p4+p5;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Some datalines includes missing values for the five variables, which will result in a missing value for the new variabel for these datalines.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there any way to get around this? I want to sum up the variabels, but I want SAS just to "ignore" if there is a missing value in one or more of the five variables and sum of the rest. I have thought about changning all the missing values in these 5 variable into the value of "0", but I would prefer to use a procedure that just ignores the missings values.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2019 14:50:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/558976#M74825</guid>
      <dc:creator>Biniie</dc:creator>
      <dc:date>2019-05-15T14:50:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to compute a variabel as the sum of other variables and ignore missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/558981#M74826</link>
      <description>&lt;P&gt;Please try the sum function as below&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Psum= sum(of p1-p5);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 15 May 2019 14:51:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/558981#M74826</guid>
      <dc:creator>Jagadishkatam</dc:creator>
      <dc:date>2019-05-15T14:51:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to compute a variabel as the sum of other variables and ignore missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/559040#M74837</link>
      <description>&lt;P&gt;And if you have actual variable names that are not as nice just list them in the sum function:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Psum = sum (thisvar, thatvar, somethingelse, othervar, varx);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you are interested most of the basic statistics are available using similar syntax: N Mean Min Max Range STD Var (variance) Skewness and others.&lt;/P&gt;</description>
      <pubDate>Wed, 15 May 2019 16:08:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/559040#M74837</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-05-15T16:08:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to compute a variabel as the sum of other variables and ignore missing values</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/562366#M74940</link>
      <description>&lt;P&gt;Perfect, thanks!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2019 17:36:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-compute-a-variabel-as-the-sum-of-other-variables-and/m-p/562366#M74940</guid>
      <dc:creator>Biniie</dc:creator>
      <dc:date>2019-05-29T17:36:54Z</dc:date>
    </item>
  </channel>
</rss>

