Proc Report - Bold column headings

Reply
Contributor
Posts: 68

Proc Report - Bold column headings

Hello, this code shows a table where the title is the first part of the table, followed by column headers where I have a sub title to the right. It successfully bolds the table/title but NOT the columns starting with state and ending with per5. I have tried too many efforts without asking you... help?! Smiley Happy

column

(('~S={fontweight=bold borderbottomcolor=black just=l borderbottomwidth=2}

Table 1. Number of Individuals ~{super 1}:  FY2013'

(state case ave ('Number of Individuals in As ~S={just=right borderbottomcolor=black borderbottomwidth=2}'

(pers1 pers2 pers3 pers4 pers5)) ) ));

SORT OF LIKE THIS:

Table 1.  Number of Individuals1:  FY2013

                                                      Number of Individuals 

State     Total      Average Size      1     2     3    4    5 or More

Super User
Posts: 11,343

Re: Proc Report - Bold column headings

Generally style modifiers come before the text to be modified.

Without the full code of the proc report it's kind of hard to guess where specific lines of code need to be changed.

Contributor
Posts: 68

Re: Proc Report - Bold column headings

Thanks Ballad!

option nomprint nosymbolgen nomlogic nodate nonumber orientation=portrait ;

title;

ods rtf file = 'C:\Users\.\final.rtf' startpage = no bodytitle style= textstyle;

ods escapechar='~';

proc report nowindows data=out.table1_final split = '^'

style(report)={font_face= arial outputwidth=6.8in rules=none frame=void cellpadding=.5pt cellspacing=.9pt}

style(header)= {font_face= arial background=white borderbottomcolor=black fontsize=8.3pt}

style(column)= {font_face= arial fontsize=8.3pt};

column

(('~S={fontweight=bold borderbottomcolor=black just=l borderbottomwidth=2}

Table 1.  Number of Individuals in the Unit

~{super 1}: FY2013'

('~S={fontweight=bold}state cases avepers

(Number of Individuals in Unit ~S={just=right borderbottomcolor=black borderbottomwidth=2}'

(pers01r pers02r pers03r pers04r pers05r)) )) );

*column ( ('~S={borderbottomcolor=black borderbottomwidth=2 fontstyle=roman fontsize=8pt

  fontweight=bold just=left}Table 1.~S={fontweight=bold}  Number

  of Individuals in the Unit1:  FY2013'

  ( state cases avepers pers01r pers02r pers03r pers04r pers05r)));

  define state/display 'State' style(column)=[cellwidth=.5in just=left rightmargin=.1in]

  style(header)={cellwidth=.5in just=left borderbottomcolor=black borderbottomwidth=1};

  define cases/display 'Total Families' style(column)=[cellwidth=.45in just=d rightmargin=.16in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  define avepers/display 'Average Size' style(column)=[cellwidth=.45in just=d rightmargin=.34in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  define pers01r/display '1' style(column)=[cellwidth=.45in just=d rightmargin=.33in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  define pers02r/display '2' style(column)=[cellwidth=.45in just=d rightmargin=.3in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  define pers03r/display '3' style(column)=[cellwidth=.45in just=d rightmargin=.35in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1 rightmargin=.1in};

  define pers04r/display '4' style(column)=[cellwidth=.45in just=d rightmargin=.3in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  define pers05r/display '5 or More' style(column)=[cellwidth=.45in just=d rightmargin=.27in]

  style(header)={cellwidth=.3in just=c borderbottomcolor=black borderbottomwidth=1};

  compute after/style=[just=l bordertopcolor=black bordertopwidth=.1];

  line '~S={font_face= arial fontsize=8pt}~{super 1} unit: Those persons whose amount of, assistance.';

  line '~S={font_face= arial fontsize=8pt} Note: Totals may not sum due to rounding.';

  line '~S={font_face= arial font_style=italic fontsize=8pt}Source~S={font_face= arial  fontsize=8pt}:  Data File as of/2014.';

endcomp;

run;

ods rtf close;

Contributor
Posts: 68

Re: Proc Report - Bold column headings

Got it!

it was super easy. I was making it harder.

style(header)= {fontweight=bold font_face= arial background=white borderbottomcolor=black fontsize=8.3pt}

Ask a Question
Discussion stats
  • 3 replies
  • 239 views
  • 1 like
  • 2 in conversation