<?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: Counting number of records under each column variable in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623686#M8763</link>
    <description>&lt;P&gt;This is overkill for what you want but definitely gives you that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://gist.github.com/statgeek/2de1faf1644dc8160fe721056202f111" target="_blank"&gt;https://gist.github.com/statgeek/2de1faf1644dc8160fe721056202f111&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Otherwise a PROC MEANS is likley all you need, assuming numeric variables - results are stored in the 'want' data set. The solution above works regardless of types.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc means data=sashelp.class N NMISS;
ods output summary=want;
run;

proc print data=want;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/190754"&gt;@ak2011&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;Hi,&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;I would greatly appreciate if somone could help me with the SAS code to count number of observations/records under each column variable in the attached table(Table 1).&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;My task is I want to count the number of pop cont and can cont under each of the variables lung loat lsquam ladeno.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;I know that probably I need to use proc means or proc freq to do the counts but I am not sure about the right code.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;Any help,please? Thanks in advance.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;ak.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;72&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;73 /* Cell Types*/&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;74 data ncells(keep=lung loat lsquam ladeno);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;75 set bgmg1(obs=70);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;76 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote1_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.BGMG1.&lt;/DIV&gt;
&lt;DIV id="sasLogNote2_1581364936389" class="sasNote"&gt;NOTE: The data set WORK.NCELLS has 70 observations and 4 variables.&lt;/DIV&gt;
&lt;DIV id="sasLogNote3_1581364936389" class="sasNote"&gt;NOTE: DATA statement used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.01 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.02 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;77&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;78 proc print data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;79 Title " Table 1. Cancer information";&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;80 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote4_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote5_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE PRINT used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;81&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;82 proc freq data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;83 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote6_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote7_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE FREQ used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.24 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.23 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;84&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;85 proc means data=ncells; run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote8_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote9_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE MEANS used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.17 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.15 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;86&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;87&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;88 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;100&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;PRE id="pre_sasLog_343" class="sasLog"&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 10 Feb 2020 20:28:48 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2020-02-10T20:28:48Z</dc:date>
    <item>
      <title>Counting number of records under each column variable</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623677#M8758</link>
      <description>&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;Hi,&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;I would greatly appreciate if somone could help me with the SAS code to count number of observations/records under each column variable in the attached table(Table 1).&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;My task is I want to count the number of pop cont and can cont under each of the variables lung loat lsquam ladeno.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;I know that probably I need to use proc means or proc freq to do the counts but I am not sure about the right code.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;Any help,please? Thanks in advance.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;ak.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;72&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;73 /* Cell Types*/&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;74 data ncells(keep=lung loat lsquam ladeno);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;75 set bgmg1(obs=70);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;76 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote1_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.BGMG1.&lt;/DIV&gt;
&lt;DIV id="sasLogNote2_1581364936389" class="sasNote"&gt;NOTE: The data set WORK.NCELLS has 70 observations and 4 variables.&lt;/DIV&gt;
&lt;DIV id="sasLogNote3_1581364936389" class="sasNote"&gt;NOTE: DATA statement used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.01 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.02 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;77&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;78 proc print data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;79 Title " Table 1. Cancer information";&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;80 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote4_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote5_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE PRINT used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;81&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;82 proc freq data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;83 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote6_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote7_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE FREQ used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.24 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.23 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;84&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;85 proc means data=ncells; run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote8_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote9_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE MEANS used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.17 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.15 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;86&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;87&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;88 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;100&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;PRE id="pre_sasLog_343" class="sasLog"&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Feb 2020 20:12:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623677#M8758</guid>
      <dc:creator>ak2011</dc:creator>
      <dc:date>2020-02-10T20:12:04Z</dc:date>
    </item>
    <item>
      <title>Re: Counting number of records under each column variable</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623682#M8761</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;My task is I want to count the number of pop cont and can cont under each of the variables lung loat lsquam ladeno.&lt;/SPAN&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;As I look at the output in your attached file, it seems as if you have programmed SAS to do this counting. So I'm not sure what you are asking.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Feb 2020 20:21:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623682#M8761</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-02-10T20:21:38Z</dc:date>
    </item>
    <item>
      <title>Re: Counting number of records under each column variable</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623686#M8763</link>
      <description>&lt;P&gt;This is overkill for what you want but definitely gives you that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://gist.github.com/statgeek/2de1faf1644dc8160fe721056202f111" target="_blank"&gt;https://gist.github.com/statgeek/2de1faf1644dc8160fe721056202f111&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Otherwise a PROC MEANS is likley all you need, assuming numeric variables - results are stored in the 'want' data set. The solution above works regardless of types.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc means data=sashelp.class N NMISS;
ods output summary=want;
run;

proc print data=want;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/190754"&gt;@ak2011&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;Hi,&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;I would greatly appreciate if somone could help me with the SAS code to count number of observations/records under each column variable in the attached table(Table 1).&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;My task is I want to count the number of pop cont and can cont under each of the variables lung loat lsquam ladeno.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;I know that probably I need to use proc means or proc freq to do the counts but I am not sure about the right code.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;Any help,please? Thanks in advance.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;ak.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;72&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;73 /* Cell Types*/&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasSource"&gt;74 data ncells(keep=lung loat lsquam ladeno);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;75 set bgmg1(obs=70);&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;76 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote1_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.BGMG1.&lt;/DIV&gt;
&lt;DIV id="sasLogNote2_1581364936389" class="sasNote"&gt;NOTE: The data set WORK.NCELLS has 70 observations and 4 variables.&lt;/DIV&gt;
&lt;DIV id="sasLogNote3_1581364936389" class="sasNote"&gt;NOTE: DATA statement used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.01 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.02 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;77&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;78 proc print data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;79 Title " Table 1. Cancer information";&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;80 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote4_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote5_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE PRINT used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.43 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;81&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;82 proc freq data=ncells;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;83 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote6_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote7_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE FREQ used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.24 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.23 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;84&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;85 proc means data=ncells; run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote8_1581364936389" class="sasNote"&gt;NOTE: There were 70 observations read from the data set WORK.NCELLS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote9_1581364936389" class="sasNote"&gt;NOTE: PROCEDURE MEANS used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.17 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.15 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;86&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;87&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;88 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;100&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;PRE id="pre_sasLog_343" class="sasLog"&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Feb 2020 20:28:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623686#M8763</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-02-10T20:28:48Z</dc:date>
    </item>
    <item>
      <title>Re: Counting number of records under each column variable</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623695#M8764</link>
      <description>&lt;P&gt;You may get a better answer if you provide:&lt;/P&gt;
&lt;P&gt;1) a small example data set as data step code.&lt;/P&gt;
&lt;P&gt;2) What you expect for the result given that example data.&lt;/P&gt;
&lt;P&gt;The example should be big enough to demonstrate some difference in the resulting count but small enough you can create the output by hand to show the desired result and layout.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's something similar to what I think you are wanting, a single table with the counts per column heading.&lt;/P&gt;
&lt;PRE&gt;data example;
   input var1 $ var2 $ var3 $;
datalines;
A B  A
A A  B
A B  B
A B  A
B B  B
B A  A
B B  A
;

data temp;
   set example;
   array v var1 var2 var3;
   do i=1 to dim(v);
      name = vname(v[i]);
      value = v[i];
      output;
   end;
run;

proc tabulate data=temp;
   class name value;
   table value,name
   ;
run;
&lt;/PRE&gt;</description>
      <pubDate>Mon, 10 Feb 2020 20:49:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623695#M8764</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-02-10T20:49:28Z</dc:date>
    </item>
    <item>
      <title>Re: Counting number of records under each column variable</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623701#M8766</link>
      <description>Thank you. I will provide a small dataset then.</description>
      <pubDate>Mon, 10 Feb 2020 21:11:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Counting-number-of-records-under-each-column-variable/m-p/623701#M8766</guid>
      <dc:creator>ak2011</dc:creator>
      <dc:date>2020-02-10T21:11:26Z</dc:date>
    </item>
  </channel>
</rss>

