<?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 keep highest value using proc sort in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/keep-highest-value-using-proc-sort/m-p/557677#M10008</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data raw; set rawdata;
     keep day year title number;
proc sort data=raw nodupkey; by day year; run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;How could I modify this code to keep the day and year with the highest number if raw data contained multiple different values of numbers, instead of just a single value?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
    <pubDate>Fri, 10 May 2019 04:26:31 GMT</pubDate>
    <dc:creator>RebeccaJW</dc:creator>
    <dc:date>2019-05-10T04:26:31Z</dc:date>
    <item>
      <title>keep highest value using proc sort</title>
      <link>https://communities.sas.com/t5/New-SAS-User/keep-highest-value-using-proc-sort/m-p/557677#M10008</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data raw; set rawdata;
     keep day year title number;
proc sort data=raw nodupkey; by day year; run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;How could I modify this code to keep the day and year with the highest number if raw data contained multiple different values of numbers, instead of just a single value?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 04:26:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/keep-highest-value-using-proc-sort/m-p/557677#M10008</guid>
      <dc:creator>RebeccaJW</dc:creator>
      <dc:date>2019-05-10T04:26:31Z</dc:date>
    </item>
    <item>
      <title>Re: keep highest value using proc sort</title>
      <link>https://communities.sas.com/t5/New-SAS-User/keep-highest-value-using-proc-sort/m-p/557678#M10009</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data raw; set rawdata;
     keep day year title number;
proc sort data=raw ; 
by day year descending number; run;

data want;
set raw;
by day year;
if first.year;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Would the above work?&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 04:57:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/keep-highest-value-using-proc-sort/m-p/557678#M10009</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2019-05-10T04:57:02Z</dc:date>
    </item>
  </channel>
</rss>

