<?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 compare the data in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199403#M49861</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Team,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have dataset with data this way&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data dataset1;&lt;/P&gt;&lt;P&gt;input v1 v2;&lt;/P&gt;&lt;P&gt;cards;&lt;/P&gt;&lt;P&gt;10 12&lt;/P&gt;&lt;P&gt;12 21&lt;/P&gt;&lt;P&gt;23 22&lt;/P&gt;&lt;P&gt;22 45&lt;/P&gt;&lt;P&gt;33 24&lt;/P&gt;&lt;P&gt;; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I am expecting the output which would diagonally compare and provides me the max value .. if diagonally&amp;nbsp; value was not found then it should return the same value with the column v2 (33 24 seen below)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;output:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;V1 V2&lt;/P&gt;&lt;P&gt;10 21&lt;/P&gt;&lt;P&gt;23 45&lt;/P&gt;&lt;P&gt;33 24&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help on this is really appreciated..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 11 Mar 2015 18:18:40 GMT</pubDate>
    <dc:creator>mvk_sas</dc:creator>
    <dc:date>2015-03-11T18:18:40Z</dc:date>
    <item>
      <title>compare the data</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199403#M49861</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Team,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have dataset with data this way&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data dataset1;&lt;/P&gt;&lt;P&gt;input v1 v2;&lt;/P&gt;&lt;P&gt;cards;&lt;/P&gt;&lt;P&gt;10 12&lt;/P&gt;&lt;P&gt;12 21&lt;/P&gt;&lt;P&gt;23 22&lt;/P&gt;&lt;P&gt;22 45&lt;/P&gt;&lt;P&gt;33 24&lt;/P&gt;&lt;P&gt;; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I am expecting the output which would diagonally compare and provides me the max value .. if diagonally&amp;nbsp; value was not found then it should return the same value with the column v2 (33 24 seen below)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;output:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;V1 V2&lt;/P&gt;&lt;P&gt;10 21&lt;/P&gt;&lt;P&gt;23 45&lt;/P&gt;&lt;P&gt;33 24&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help on this is really appreciated..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Mar 2015 18:18:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199403#M49861</guid>
      <dc:creator>mvk_sas</dc:creator>
      <dc:date>2015-03-11T18:18:40Z</dc:date>
    </item>
    <item>
      <title>Re: compare the data</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199404#M49862</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I don't understand your output. &lt;/P&gt;&lt;P&gt;Could you elaborate!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;output:-&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;V1 V2&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;10 21&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;23 45&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;33 24&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Mar 2015 18:57:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199404#M49862</guid>
      <dc:creator>BOBSAS</dc:creator>
      <dc:date>2015-03-11T18:57:55Z</dc:date>
    </item>
    <item>
      <title>Re: compare the data</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199405#M49863</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;input v1 v2;&lt;/P&gt;&lt;P&gt;cards;&lt;/P&gt;&lt;P&gt;10 12&lt;/P&gt;&lt;P&gt;12 21&lt;/P&gt;&lt;P&gt;23 22&lt;/P&gt;&lt;P&gt;22 45&lt;/P&gt;&lt;P&gt;33 24&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data want (keep=v1 v2);&lt;/P&gt;&lt;P&gt;set have end=last;&lt;/P&gt;&lt;P&gt;x=lag(v1);&lt;/P&gt;&lt;P&gt;if mod(_n_,2)=0&amp;nbsp; then do; v1=x; output; end;&lt;/P&gt;&lt;P&gt;else if last then output;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Mar 2015 19:07:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/compare-the-data/m-p/199405#M49863</guid>
      <dc:creator>mohamed_zaki</dc:creator>
      <dc:date>2015-03-11T19:07:06Z</dc:date>
    </item>
  </channel>
</rss>

