<?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: Sum each numeric variable in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Sum-each-numeric-variable/m-p/324585#M21676</link>
    <description>&lt;P&gt;Please post example test data - in the form of a datastep - so that we can see what we are working with. &amp;nbsp;Only need a couple of lines.&lt;/P&gt;
&lt;P&gt;It may be you can use the _numeric_ in a proc means or summary to get your required output, for instance:&lt;/P&gt;
&lt;PRE&gt;proc summary data=sashelp.class;&lt;BR /&gt; var _numeric_;&lt;BR /&gt; output out=sumry sum=;&lt;BR /&gt;run;&lt;/PRE&gt;
&lt;P&gt;Edit, the above code should work.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Jan 2017 15:05:27 GMT</pubDate>
    <dc:creator>RW9</dc:creator>
    <dc:date>2017-01-13T15:05:27Z</dc:date>
    <item>
      <title>Sum each numeric variable</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Sum-each-numeric-variable/m-p/324571#M21675</link>
      <description>&lt;P&gt;Folks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I currently have a dataset with 400 variables for 1,000,000 indivduals. I've been given a list of totals for certain variables however, the names are different to what's in my dataset.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Therefore, I would like to sum each of my variables in order to create a total for each variable, so going from 1,000,000 plus cases to just 1 for each varaible, with the 1 being the sum of all cases.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Each of the variables in my dataset have different names, but also there are character variables in it also.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Would anyone be able to suggest a work around for what I wish to do, or perhaps a simpler method to what I've proposed?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sean&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jan 2017 14:45:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Sum-each-numeric-variable/m-p/324571#M21675</guid>
      <dc:creator>Sean_OConnor</dc:creator>
      <dc:date>2017-01-13T14:45:27Z</dc:date>
    </item>
    <item>
      <title>Re: Sum each numeric variable</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Sum-each-numeric-variable/m-p/324585#M21676</link>
      <description>&lt;P&gt;Please post example test data - in the form of a datastep - so that we can see what we are working with. &amp;nbsp;Only need a couple of lines.&lt;/P&gt;
&lt;P&gt;It may be you can use the _numeric_ in a proc means or summary to get your required output, for instance:&lt;/P&gt;
&lt;PRE&gt;proc summary data=sashelp.class;&lt;BR /&gt; var _numeric_;&lt;BR /&gt; output out=sumry sum=;&lt;BR /&gt;run;&lt;/PRE&gt;
&lt;P&gt;Edit, the above code should work.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jan 2017 15:05:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Sum-each-numeric-variable/m-p/324585#M21676</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-01-13T15:05:27Z</dc:date>
    </item>
  </channel>
</rss>

