<?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 Unique summing situation in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75807#M22007</link>
    <description>I need to sum data across a row (layers) say for a road surface. &lt;BR /&gt;
&lt;BR /&gt;
P=Pavement&lt;BR /&gt;
M=Milling&lt;BR /&gt;
B=Base&lt;BR /&gt;
&lt;BR /&gt;
Such as P .30, P 1.0, P 4.0, M -4.0, P 2.0, B .70, P 2.3. If P represented the data i needed to sum from left to right, subtracting the M from only the numbers past the M.  &lt;BR /&gt;
&lt;BR /&gt;
A. (P .30 + P 1.0 + P 4.0)  = 5.30&lt;BR /&gt;
&lt;BR /&gt;
B. (M -4.0 - P 2.0 + B .70 + P 2.3) = 1&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
A. + B. = 6.3</description>
    <pubDate>Tue, 20 Apr 2010 18:58:38 GMT</pubDate>
    <dc:creator>deleted_user</dc:creator>
    <dc:date>2010-04-20T18:58:38Z</dc:date>
    <item>
      <title>Unique summing situation</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75807#M22007</link>
      <description>I need to sum data across a row (layers) say for a road surface. &lt;BR /&gt;
&lt;BR /&gt;
P=Pavement&lt;BR /&gt;
M=Milling&lt;BR /&gt;
B=Base&lt;BR /&gt;
&lt;BR /&gt;
Such as P .30, P 1.0, P 4.0, M -4.0, P 2.0, B .70, P 2.3. If P represented the data i needed to sum from left to right, subtracting the M from only the numbers past the M.  &lt;BR /&gt;
&lt;BR /&gt;
A. (P .30 + P 1.0 + P 4.0)  = 5.30&lt;BR /&gt;
&lt;BR /&gt;
B. (M -4.0 - P 2.0 + B .70 + P 2.3) = 1&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
A. + B. = 6.3</description>
      <pubDate>Tue, 20 Apr 2010 18:58:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75807#M22007</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-04-20T18:58:38Z</dc:date>
    </item>
    <item>
      <title>Re: Unique summing situation</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75808#M22008</link>
      <description>In order to get a good answer you should provide us with a sample data set (a SAS data step creating a SAS table) and then tell us how the result should look like.&lt;BR /&gt;
&lt;BR /&gt;
As a general answer to your question:&lt;BR /&gt;
Use an ARRAY and loop over it.</description>
      <pubDate>Wed, 21 Apr 2010 01:35:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75808#M22008</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2010-04-21T01:35:01Z</dc:date>
    </item>
    <item>
      <title>Re: Unique summing situation</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75809#M22009</link>
      <description>&lt;U&gt;CODE&lt;/U&gt; DEPTH&lt;BR /&gt;
&lt;U&gt;20&lt;/U&gt;	1.00         &lt;U&gt; 45&lt;/U&gt;	9.00	&lt;U&gt;21.1&lt;/U&gt;	-4.75	 &lt;U&gt; 08&lt;/U&gt; 1.00	  &lt;U&gt;06&lt;/U&gt;	0.50          &lt;U&gt;08&lt;/U&gt;	1.50	  &lt;BR /&gt;
&lt;U&gt;20&lt;/U&gt;	 0.75	  &lt;U&gt;21.1&lt;/U&gt;          -2.2         &lt;U&gt;08&lt;/U&gt;	1.50           &lt;U&gt;20&lt;/U&gt;         0.50	  &lt;U&gt;21.2&lt;/U&gt;          -2.00       &lt;U&gt;08&lt;/U&gt;           1.25	  &lt;BR /&gt;
&lt;U&gt;20&lt;/U&gt;	 0.75	  &lt;U&gt;21.1&lt;/U&gt;          -2.25       &lt;U&gt; 08&lt;/U&gt;	1.50            &lt;U&gt;21.2&lt;/U&gt;     -2.00	  &lt;U&gt;08&lt;/U&gt;	            1.25       &lt;U&gt; 25&lt;/U&gt;	9.00&lt;BR /&gt;
&lt;BR /&gt;
I NEED TO GO ACROSS THE ROW FROM LEFT TO RIGHT, BUT IT HAS TO STEP FROM LEFT TO RIGHT DEPTH ONE +- DEPTH TWO AND SO ON AND SO FORTH. I CAN'T USE A SUM BECAUSE IT WILL ADD EVERYTHING THE SUBTRACT THE -'S FROM THE TOTAL. IF THERE IS A NEG NUMBER NEAR THE END SAY -3.00 THEN 2.00 THERE WOULD BE -1.00 LEFT I NEED THAT TO DELETE THEN.</description>
      <pubDate>Thu, 22 Apr 2010 15:18:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Unique-summing-situation/m-p/75809#M22009</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-04-22T15:18:14Z</dc:date>
    </item>
  </channel>
</rss>

