<?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: Design a table header flexibly in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492293#M21594</link>
    <description>&lt;P&gt;Thanks for your answer. I want to write a macro mreport to deal with the table head. The table data has been calculated before.&lt;/P&gt;&lt;P&gt;I want to use the&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;header parameters (in above case the parameters are head1 and head2) only, to form the table head, without other information of the table. This will make the macro more general.&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="comment-copy"&gt;If there is rtf grammer to recognize such form(!!!SS!FAS!PPS!)directly?&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If exists, it will make the macro more easier.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 04 Sep 2018 13:54:52 GMT</pubDate>
    <dc:creator>wikich</dc:creator>
    <dc:date>2018-09-04T13:54:52Z</dc:date>
    <item>
      <title>Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492229#M21591</link>
      <description>&lt;P&gt;I want to create a table head for a table, replacing the orignal table head.&lt;/P&gt;&lt;P&gt;The table head contains two rows:&lt;/P&gt;&lt;P&gt;head1 = !!!SS!FAS!PPS!&lt;/P&gt;&lt;P&gt;head2 = !Index!!(N=30)!(N=30)!(N=30)!&lt;/P&gt;&lt;P&gt;Here the ! meaning column delimiter. The head1 is the first row of table head .In head1, the first and second column&amp;nbsp;are blank and the content of third, fourth and fifith are SS, FAS and PPS.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The head2 is the second row of table head, the content of the first column is index; the second is blank; the third to fifth are (N-30).&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I want to form the following table head:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="table_head.png" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/22964i5588D20C510D072C/image-size/large?v=v2&amp;amp;px=999" role="button" title="table_head.png" alt="table_head.png" /&gt;&lt;/span&gt;&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;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 08:59:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492229#M21591</guid>
      <dc:creator>wikich</dc:creator>
      <dc:date>2018-09-04T08:59:33Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492236#M21592</link>
      <description>&lt;P&gt;Your question is a bit vague I am afraid.&amp;nbsp; Creation of Table output for clinical reports is pretty simple, just apply some bits in the proc report:&lt;/P&gt;
&lt;PRE&gt;proc sql noprint;
  select count distinct usubjid) from adsl where ss="Y" into :ss;
  select count distinct usubjid) from adsl where fas="Y" into :fas;
  select count distinct usubjid) from adsl where pps="Y" into :pps;
quit;

ods rtf...;

proc report data=yourdata split="*";
  columns _all_;
  define ss_count / "SS*(%trim(&amp;amp;ss.))";
  define fas_count / "FAS*(%trim(&amp;amp;fas.))";
  define pps_count / "PPS*(%trim(&amp;amp;pps.))";
run;

ods rtf close;
&lt;/PRE&gt;</description>
      <pubDate>Tue, 04 Sep 2018 09:36:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492236#M21592</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-09-04T09:36:21Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492273#M21593</link>
      <description>&lt;P&gt;There’s an old paper by Cynthia Zender that walks through how to create clinical tables. It’s titled Creating Complex Reports amd has the ful code and data attached for practice.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 13:26:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492273#M21593</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-09-04T13:26:58Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492293#M21594</link>
      <description>&lt;P&gt;Thanks for your answer. I want to write a macro mreport to deal with the table head. The table data has been calculated before.&lt;/P&gt;&lt;P&gt;I want to use the&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;header parameters (in above case the parameters are head1 and head2) only, to form the table head, without other information of the table. This will make the macro more general.&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="comment-copy"&gt;If there is rtf grammer to recognize such form(!!!SS!FAS!PPS!)directly?&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If exists, it will make the macro more easier.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 13:54:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492293#M21594</guid>
      <dc:creator>wikich</dc:creator>
      <dc:date>2018-09-04T13:54:52Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492300#M21595</link>
      <description>Thanks, Reeza for the shout out about that paper. It was a popular one. But, yes, hard to believe it is 10 years old! However, that paper does not show using RTF control strings or RTF "grammar" to format something like (!!!SS!FAS!PPS!) that the OP wants to use. &lt;BR /&gt;&lt;BR /&gt;Cynthia</description>
      <pubDate>Tue, 04 Sep 2018 14:03:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492300#M21595</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2018-09-04T14:03:29Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492304#M21596</link>
      <description>&lt;P&gt;Yes, I have seen this type of thing before.&amp;nbsp; What I can tell you is that using such a macro is a real pain in the neck and they do not work half the time or do what you want.&amp;nbsp; It is far simpler to either create a report for each output, or have a template file that then gets updated per the output requirements.&amp;nbsp; Remember, SAS is very flexible, wrapping it in macro code reduces the flexibility (and simplicity in understanding the code).&amp;nbsp; Up to you of course, just I have seen it a lot.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:09:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492304#M21596</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-09-04T14:09:23Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492314#M21597</link>
      <description>&lt;P&gt;It is hard to create the header to a table in a report without also creating the actual table.&lt;/P&gt;
&lt;P&gt;Can you show a simple example of how you intend to use this in a program?&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:23:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492314#M21597</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2018-09-04T14:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492324#M21599</link>
      <description>&lt;P&gt;Thank you Reeza. I have found the article and begin to read her code.&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:50:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492324#M21599</guid>
      <dc:creator>wikich</dc:creator>
      <dc:date>2018-09-04T14:50:33Z</dc:date>
    </item>
    <item>
      <title>Re: Design a table header flexibly</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492327#M21600</link>
      <description>&lt;P&gt;Just a last note, rather than tags, you can use templates to control&amp;nbsp;layout and styles.&lt;/P&gt;
&lt;P&gt;The RTF style here, originally written by a colleague, was what we used to create our clinical reports for journal submissions. There's a little example at the bottom of the code&amp;nbsp;that illustrates the output.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://gist.github.com/statgeek/9603140" target="_blank"&gt;https://gist.github.com/statgeek/9603140&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is a bit more complex but may help. It uses the Report Writing Interface and is fairly well documented:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.pharmasug.org/proceedings/2013/CC/PharmaSUG-2013-CC13.pdf" target="_blank"&gt;https://www.pharmasug.org/proceedings/2013/CC/PharmaSUG-2013-CC13.pdf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Sep 2018 15:01:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Design-a-table-header-flexibly/m-p/492327#M21600</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-09-04T15:01:05Z</dc:date>
    </item>
  </channel>
</rss>

