<?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: Is it possible to show obs when happens something and immediately next obs? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Is-it-possible-to-show-obs-when-happens-something-and/m-p/412596#M100904</link>
    <description>&lt;P&gt;Sure, using a RETAINed variable. Here is an example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
retain flag;
set sashelp.class;
condition = age = 14;
if flag then output;
else if condition then output;
flag = condition;
drop flag condition;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Sat, 11 Nov 2017 19:33:00 GMT</pubDate>
    <dc:creator>PGStats</dc:creator>
    <dc:date>2017-11-11T19:33:00Z</dc:date>
    <item>
      <title>Is it possible to show obs when happens something and immediately next obs?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Is-it-possible-to-show-obs-when-happens-something-and/m-p/412592#M100901</link>
      <description>&lt;P&gt;I have a dataset with multiple obs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I only want to show obs when occur some condition and immediately next obs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I dont want to put two conditions because other obs can satisfy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
      <pubDate>Sat, 11 Nov 2017 18:31:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Is-it-possible-to-show-obs-when-happens-something-and/m-p/412592#M100901</guid>
      <dc:creator>dali74</dc:creator>
      <dc:date>2017-11-11T18:31:23Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to show obs when happens something and immediately next obs?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Is-it-possible-to-show-obs-when-happens-something-and/m-p/412596#M100904</link>
      <description>&lt;P&gt;Sure, using a RETAINed variable. Here is an example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
retain flag;
set sashelp.class;
condition = age = 14;
if flag then output;
else if condition then output;
flag = condition;
drop flag condition;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 11 Nov 2017 19:33:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Is-it-possible-to-show-obs-when-happens-something-and/m-p/412596#M100904</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2017-11-11T19:33:00Z</dc:date>
    </item>
  </channel>
</rss>

