DATA Step, Macro, Functions and more

Proc report and Bold

Reply
Super Contributor
Posts: 673

Proc report and Bold

By default when we get variable names in BOLD when using proc report.How to get the variables without BOLD?
SAS Super FREQ
Posts: 8,868

Re: Proc report and Bold

Hi:
This is more of a PROC REPORT/ODS question, than a SAS Macro question, since the answer depends on
1) What destination you are using (LISTING, HTML, RTF, PDF)
2) What style template you are using (none, default for the destination, a custom style template).

In the LISTING destination (or OUTPUT window), it is really not possible to change the appearance of the output. However, in ODS destinations, you can either change the PROC REPORT appearance by:
1) changing the style template that you are using with ODS
2) changing the PROC REPORT code itself using STYLE= overrides

cynthia

For example, in the code below, all the headers are changed to be black print on a white background, except for NAME, which is changed to pink background and HEIGHT, which has font_weight changed to medium (instead of bold) and font_face changed to Courier New -- so the change can be easily found.

cynthia
[pre]
ods listing close;
ods pdf file='change_hdr.pdf';
ods rtf file='change_hdr.rtf';
ods html file='change_hdr.html' style=sasweb;

proc report data=sashelp.class nowd
style(header)={foreground=black background=white};
column name sex age height weight;
define name / style(header)={background=pink};
define height / style(header)={font_weight=medium font_face="Courier New"};
run;

ods _all_ close;
[/pre]

If you want to make style template changes, there are many Tech Support notes on how to change style templates.
Ask a Question
Discussion stats
  • 1 reply
  • 126 views
  • 0 likes
  • 2 in conversation