<?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 Tabulate, mean, and denominator in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Tabulate-mean-and-denominator/m-p/52160#M14336</link>
    <description>If the mean of a variable is referenced in a tabulate, and then once again the variable is referenced as a denominator, will the mean be used?&lt;BR /&gt;
&lt;BR /&gt;
Suppose I have a dataset which contains 12 records.  One for every month.  On that record is a variable called call_dropped, and another variable called total calls.&lt;BR /&gt;
&lt;BR /&gt;
For a monthly report, the percent of calls dropped would be expressed as &lt;BR /&gt;
&lt;BR /&gt;
proc tabulate data=mydata&lt;BR /&gt;
calls_dropped      =   ''*sum='Calls Dropped'*f=comma6.&lt;BR /&gt;
total_calls           =   ''*sum='Total Calls'*f=comma9.&lt;BR /&gt;
calls_dropped      =pctsum&lt;TOTAL_CALLS&gt;='Percent Dropped'*f=pctfmt8.2,&lt;BR /&gt;
month=' '&lt;BR /&gt;
/box='Call Data';&lt;BR /&gt;
&lt;BR /&gt;
BUT, If I wanted a yearly average, I would do the following:&lt;BR /&gt;
&lt;BR /&gt;
calls_dropped      =   ''*mean='Avg. Calls Dropped per Month'*f=comma6.&lt;BR /&gt;
total_calls           =   ''*mean='Avg. Total Calls per Month'*f=comma9.&lt;BR /&gt;
calls_dropped      =pctsum&lt;TOTAL_CALLS&gt;='Avg. Percent Dropped per Month'*f=pctfmt8.2,&lt;BR /&gt;
month=' '&lt;BR /&gt;
/box='Call Data';&lt;BR /&gt;
&lt;BR /&gt;
Since there is no pctmean, what would the denominator for this expression be?  The mean of all 12 months (as I would like), or the sum of all 12 months (not good).&lt;/TOTAL_CALLS&gt;&lt;/TOTAL_CALLS&gt;</description>
    <pubDate>Sun, 18 Jul 2010 23:00:44 GMT</pubDate>
    <dc:creator>steve_citi</dc:creator>
    <dc:date>2010-07-18T23:00:44Z</dc:date>
    <item>
      <title>Tabulate, mean, and denominator</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Tabulate-mean-and-denominator/m-p/52160#M14336</link>
      <description>If the mean of a variable is referenced in a tabulate, and then once again the variable is referenced as a denominator, will the mean be used?&lt;BR /&gt;
&lt;BR /&gt;
Suppose I have a dataset which contains 12 records.  One for every month.  On that record is a variable called call_dropped, and another variable called total calls.&lt;BR /&gt;
&lt;BR /&gt;
For a monthly report, the percent of calls dropped would be expressed as &lt;BR /&gt;
&lt;BR /&gt;
proc tabulate data=mydata&lt;BR /&gt;
calls_dropped      =   ''*sum='Calls Dropped'*f=comma6.&lt;BR /&gt;
total_calls           =   ''*sum='Total Calls'*f=comma9.&lt;BR /&gt;
calls_dropped      =pctsum&lt;TOTAL_CALLS&gt;='Percent Dropped'*f=pctfmt8.2,&lt;BR /&gt;
month=' '&lt;BR /&gt;
/box='Call Data';&lt;BR /&gt;
&lt;BR /&gt;
BUT, If I wanted a yearly average, I would do the following:&lt;BR /&gt;
&lt;BR /&gt;
calls_dropped      =   ''*mean='Avg. Calls Dropped per Month'*f=comma6.&lt;BR /&gt;
total_calls           =   ''*mean='Avg. Total Calls per Month'*f=comma9.&lt;BR /&gt;
calls_dropped      =pctsum&lt;TOTAL_CALLS&gt;='Avg. Percent Dropped per Month'*f=pctfmt8.2,&lt;BR /&gt;
month=' '&lt;BR /&gt;
/box='Call Data';&lt;BR /&gt;
&lt;BR /&gt;
Since there is no pctmean, what would the denominator for this expression be?  The mean of all 12 months (as I would like), or the sum of all 12 months (not good).&lt;/TOTAL_CALLS&gt;&lt;/TOTAL_CALLS&gt;</description>
      <pubDate>Sun, 18 Jul 2010 23:00:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Tabulate-mean-and-denominator/m-p/52160#M14336</guid>
      <dc:creator>steve_citi</dc:creator>
      <dc:date>2010-07-18T23:00:44Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, mean, and denominator</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Tabulate-mean-and-denominator/m-p/52161#M14337</link>
      <description>Hi:&lt;BR /&gt;
  Is this the same data scenario as in this previous posting?&lt;BR /&gt;
&lt;A href="http://support.sas.com/forums/message.jspa?messageID=38685#38685" target="_blank"&gt;http://support.sas.com/forums/message.jspa?messageID=38685#38685&lt;/A&gt;&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Mon, 19 Jul 2010 00:22:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Tabulate-mean-and-denominator/m-p/52161#M14337</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2010-07-19T00:22:39Z</dc:date>
    </item>
  </channel>
</rss>

