Desktop productivity for business analysts and programmers

Summary Table

Reply
Occasional Contributor
Posts: 11

Summary Table

Below is a Summary table and code for it. Is it possible to color the columns´ content (heading and data) with different colors for different level of class variable FLAG (1 and 2) ?

FLAG
1 2
OVFL Sum 8170.90 120561.00
TOTAL Sum 10562.24 156204.00





PROC TABULATE
DATA=WORK.D03_REPORT_TABLE_AVG(FIRSTOBS=1 )

;

VAR OVFL TOTAL;
CLASS FLAG / ORDER=UNFORMATTED MISSING;
TABLE /* Row Dimension */
OVFL*
Sum
TOTAL*
Sum,
/* Column Dimension */
FLAG ;
;

RUN;
SAS Super FREQ
Posts: 8,720

Re: Summary Table

Hi:
PROC TABULATE allows the use of the CLASSLEV statement, along with style=<parent> in order to produce "banded" reports, where the calculated data cells inherit their colors from the parent header cells.

In order for this to work, you might have to move your SUM statistic into the COL dimension instead of the ROW dimension. For an example, see pages 17-20 in the PROC TABULATE section of this paper:
http://support.sas.com/resources/papers/stylesinprocs.pdf

cynthia
Occasional Contributor
Posts: 11

Re: Summary Table

Thank you for the real assistance!
Ask a Question
Discussion stats
  • 2 replies
  • 129 views
  • 0 likes
  • 2 in conversation