<?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: How to extract observations who have information for each month in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514721#M2789</link>
    <description>&lt;P&gt;Post test data in the form of a datastep.&lt;/P&gt;
&lt;P&gt;A simple where seems to cover your request:&lt;/P&gt;
&lt;PRE&gt;data want;
  set have;
  where hospital="RC" and nr_beds ne .;
run;&lt;/PRE&gt;</description>
    <pubDate>Tue, 20 Nov 2018 12:25:59 GMT</pubDate>
    <dc:creator>RW9</dc:creator>
    <dc:date>2018-11-20T12:25:59Z</dc:date>
    <item>
      <title>How to extract observations who have information for each month</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514720#M2788</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have this information (this is just an example):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Year Month Hospital Nr_beds&lt;/P&gt;
&lt;P&gt;2016 12 RA 210&lt;/P&gt;
&lt;P&gt;2017 1 RA 215&lt;/P&gt;
&lt;P&gt;2017 2 RA .&lt;/P&gt;
&lt;P&gt;2016 12 RB&amp;nbsp;.&lt;/P&gt;
&lt;P&gt;2017 1 RB&amp;nbsp;650&lt;/P&gt;
&lt;P&gt;2017 2 RB&amp;nbsp;651&lt;/P&gt;
&lt;P&gt;2016 12 RC 120&lt;/P&gt;
&lt;P&gt;2017 1 RC&amp;nbsp;150&lt;/P&gt;
&lt;P&gt;2017 2 RC&amp;nbsp;170&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to extract only hospital who has no missing values in the variable Nr_beds. In new table I want to have just hospital RC, but not RA (cause it does not have information for time 2017/2) and hospital RB (cause it does not have information for time 2016/12)&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 12:10:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514720#M2788</guid>
      <dc:creator>viollete</dc:creator>
      <dc:date>2018-11-20T12:10:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract observations who have information for each month</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514721#M2789</link>
      <description>&lt;P&gt;Post test data in the form of a datastep.&lt;/P&gt;
&lt;P&gt;A simple where seems to cover your request:&lt;/P&gt;
&lt;PRE&gt;data want;
  set have;
  where hospital="RC" and nr_beds ne .;
run;&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Nov 2018 12:25:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514721#M2789</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-11-20T12:25:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract observations who have information for each month</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514723#M2790</link>
      <description>&lt;PRE&gt;

data have;
input Year Month Hospital $ Nr_beds;
cards;
2016 12 RA 210
2017 1 RA 215
2017 2 RA .
2016 12 RB .
2017 1 RB 650
2017 2 RB 651
2016 12 RC 120
2017 1 RC 150
2017 2 RC 170
;

proc sql;
create table want as
 select * from have
  group by Hospital
   having nmiss(Nr_beds)=0;
quit;


&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Nov 2018 12:33:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514723#M2790</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-11-20T12:33:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract observations who have information for each month</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514724#M2791</link>
      <description>&lt;PRE&gt;

data have;
input Year Month Hospital $ Nr_beds;
cards;
2016 12 RA 210
2017 1 RA 215
2017 2 RA .
2016 12 RB .
2017 1 RB 650
2017 2 RB 651
2016 12 RC 120
2017 1 RC 150
2017 2 RC 170
;

proc sql;
create table want as
 select * from have
  group by Hospital
   having nmiss(Nr_beds)=0;
quit;


&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Nov 2018 12:37:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-extract-observations-who-have-information-for-each-month/m-p/514724#M2791</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-11-20T12:37:21Z</dc:date>
    </item>
  </channel>
</rss>

