<?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: SAS code help in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586791#M14571</link>
    <description>&lt;P&gt;thanks for clearing that up! makes sense now!&lt;/P&gt;</description>
    <pubDate>Fri, 06 Sep 2019 15:08:40 GMT</pubDate>
    <dc:creator>mariamon0</dc:creator>
    <dc:date>2019-09-06T15:08:40Z</dc:date>
    <item>
      <title>SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586762#M14558</link>
      <description>&lt;P&gt;I am trying to determine how many "valid wear days" my participants have.&lt;/P&gt;&lt;P&gt;I have already determined a step valid to be more than 200 steps. stepvalid=1 vs. stepvalid=0&lt;/P&gt;&lt;P&gt;I want to know how many participants have 10 valid wear days 9 etc.&lt;/P&gt;&lt;P&gt;How would I code this?&lt;/P&gt;&lt;P&gt;I assume I use proc freq&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 13:32:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586762#M14558</guid>
      <dc:creator>mariamon0</dc:creator>
      <dc:date>2019-09-06T13:32:01Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586769#M14560</link>
      <description>&lt;P&gt;Can you post some sample of your data for us to work with?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Makes it much easier to provide a usable code answer&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 13:50:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586769#M14560</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-09-06T13:50:28Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586772#M14561</link>
      <description>&lt;P&gt;data stepdata3; set stepdata2;&lt;BR /&gt;format date mmddyy10. ped_date mmddyy10. match_date mmddyy10. baseline_day1 mmddyy10. baseline_day10 mmddyy10.;&lt;BR /&gt;ped_date = date;&lt;BR /&gt;if steps &amp;gt;31000 then steps = .;&lt;BR /&gt;if steps &amp;gt;= 200 then stepvalid = 1;&lt;BR /&gt;else if steps &amp;lt; 200 then stepvalid = 0;&lt;BR /&gt;else stepvalid = .;&lt;BR /&gt;match_date = ped_date;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;I want to know how many of my study_id's have 10 stepvalid days 9 stepvalid days etc.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 13:53:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586772#M14561</guid>
      <dc:creator>mariamon0</dc:creator>
      <dc:date>2019-09-06T13:53:36Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586777#M14562</link>
      <description>&lt;P&gt;A two-step counting process should make this easy:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc freq data=have;
   where stepvalid=1;
   tables study_id / noprint out=counts (rename=(count=per_study_id) ) ;
run;

proc freq data=counts;
   tables per_study_id;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;The first PROC FREQ saves the number of valid days for each Study ID.&amp;nbsp; Then the second PROC FREQ uses those counts to produce the report.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 14:21:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586777#M14562</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2019-09-06T14:21:19Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586784#M14567</link>
      <description>&lt;P&gt;But I want to know how many study ids have 10 valid step days...this doesnt produce what I need&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 14:40:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586784#M14567</guid>
      <dc:creator>mariamon0</dc:creator>
      <dc:date>2019-09-06T14:40:55Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586787#M14569</link>
      <description>&lt;P&gt;Yes it does.&amp;nbsp; Did you try it?&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The report shows two key columns:&amp;nbsp; per_study_ID and COUNT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PER_STUDY_ID is the number of valid step days per Study ID.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;COUNT is the number of Study IDs with that number of valid step days.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 14:44:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586787#M14569</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2019-09-06T14:44:46Z</dc:date>
    </item>
    <item>
      <title>Re: SAS code help</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586791#M14571</link>
      <description>&lt;P&gt;thanks for clearing that up! makes sense now!&lt;/P&gt;</description>
      <pubDate>Fri, 06 Sep 2019 15:08:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-code-help/m-p/586791#M14571</guid>
      <dc:creator>mariamon0</dc:creator>
      <dc:date>2019-09-06T15:08:40Z</dc:date>
    </item>
  </channel>
</rss>

