<?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 Pulling HTML Output Table in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268619#M53182</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using proc means and would like to create a SAS dataset that is exactly the same as&amp;nbsp;the one that&amp;nbsp;appears in the HTML output window. In the past I have been able to pull the table by using a 'ods output' statement within other SAS procedures. In this case it didn't work exactly as planned and I am left with a few questions:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1) When SAS creates the tables for the HTML output, is that dataset already temporarily saved in some physical location?&amp;nbsp;ODS trace says the path is Means.ByGroup1.Summary. However, this isn't quite helpful to me. Is there a full path so I can navigate to that file?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) If I want to create a separate table for each 'by' group, how do I do this? It seems to me that each table has the same name (Summary). Is there a way I can use the path name to differentiate?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3) Why is it that when I save the table using the code below, the table is formatted differently. I.e. rows and columns have been switched?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;ods&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;trace&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;on&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;means&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;data&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;=h.combined &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;mean&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;median&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;min&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;max&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;var&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;by&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt; clinic;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;ods&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;output&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt; summary=summary;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;Output Added:&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;Name: Summary&lt;/P&gt;&lt;P&gt;Label: Summary statistics&lt;/P&gt;&lt;P&gt;Template: base.summary&lt;/P&gt;&lt;P&gt;Path: Means.ByGroup1.Summary&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;NOTE: The above message was for the following BY group:&lt;/P&gt;&lt;P&gt;clinic=AMR&lt;/P&gt;&lt;P&gt;Output Added:&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;Name: Summary&lt;/P&gt;&lt;P&gt;Label: Summary statistics&lt;/P&gt;&lt;P&gt;Template: base.summary&lt;/P&gt;&lt;P&gt;Path: Means.ByGroup2.Summary&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 05 May 2016 17:34:59 GMT</pubDate>
    <dc:creator>Noob</dc:creator>
    <dc:date>2016-05-05T17:34:59Z</dc:date>
    <item>
      <title>Pulling HTML Output Table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268619#M53182</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using proc means and would like to create a SAS dataset that is exactly the same as&amp;nbsp;the one that&amp;nbsp;appears in the HTML output window. In the past I have been able to pull the table by using a 'ods output' statement within other SAS procedures. In this case it didn't work exactly as planned and I am left with a few questions:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1) When SAS creates the tables for the HTML output, is that dataset already temporarily saved in some physical location?&amp;nbsp;ODS trace says the path is Means.ByGroup1.Summary. However, this isn't quite helpful to me. Is there a full path so I can navigate to that file?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) If I want to create a separate table for each 'by' group, how do I do this? It seems to me that each table has the same name (Summary). Is there a way I can use the path name to differentiate?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3) Why is it that when I save the table using the code below, the table is formatted differently. I.e. rows and columns have been switched?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;ods&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;trace&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;on&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;means&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;data&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;=h.combined &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;mean&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;median&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;min&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;max&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;var&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;by&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt; clinic;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="2"&gt;ods&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="2"&gt;output&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt; summary=summary;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;FONT color="#000080" face="Courier New" size="2"&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="2"&gt;&lt;FONT face="Courier New" size="2"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;Output Added:&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;Name: Summary&lt;/P&gt;&lt;P&gt;Label: Summary statistics&lt;/P&gt;&lt;P&gt;Template: base.summary&lt;/P&gt;&lt;P&gt;Path: Means.ByGroup1.Summary&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;NOTE: The above message was for the following BY group:&lt;/P&gt;&lt;P&gt;clinic=AMR&lt;/P&gt;&lt;P&gt;Output Added:&lt;/P&gt;&lt;P&gt;-------------&lt;/P&gt;&lt;P&gt;Name: Summary&lt;/P&gt;&lt;P&gt;Label: Summary statistics&lt;/P&gt;&lt;P&gt;Template: base.summary&lt;/P&gt;&lt;P&gt;Path: Means.ByGroup2.Summary&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2016 17:34:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268619#M53182</guid>
      <dc:creator>Noob</dc:creator>
      <dc:date>2016-05-05T17:34:59Z</dc:date>
    </item>
    <item>
      <title>Re: Pulling HTML Output Table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268644#M53189</link>
      <description>&lt;P&gt;Add the STACKODS option in your proc means statement.&lt;/P&gt;
&lt;P&gt;I don't think you can get separate tables for your BY statements, in general that's not a good idea anyways.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/kb/46/427.html" target="_blank"&gt;http://support.sas.com/kb/46/427.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/proc/65145/HTML/default/viewer.htm#p17h6q7ygvkl1sn13qzf947dundi.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/proc/65145/HTML/default/viewer.htm#p17h6q7ygvkl1sn13qzf947dundi.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2016 19:10:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268644#M53189</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-05-05T19:10:43Z</dc:date>
    </item>
    <item>
      <title>Re: Pulling HTML Output Table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268681#M53202</link>
      <description>&lt;P&gt;Thanks, that is a helpful option!&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2016 20:58:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Pulling-HTML-Output-Table/m-p/268681#M53202</guid>
      <dc:creator>Noob</dc:creator>
      <dc:date>2016-05-05T20:58:34Z</dc:date>
    </item>
  </channel>
</rss>

