From: joecool on
Hi All, I'm trying to use PROC REPORT to create a complex report using
already summarized input data (example code and data, links to reports
belwo). The general problem is that most of the control in PROC REPORT
is focused on COLUMNS, whereas I also need absolute control over ROWS.
For example, I'd like to format row by row (each row is an observation
in the dataset).This is only part of the challenge...

The major solution I'm looking for requires conditional formatting.
I've seen some great examples (by A. Karp and others) of traffic
lighting using PROC REPORT and ODS. However, I'm interested in
applying conditional formatting which displays data bars (w/ rules
based on values in rows or groups of rows). This display is easy to do
in Excel 2007 and beyond. However, I'm trying to automate the process
in SAS. Thinking it will involve some sort of overlay. Starting to
question how much time to invest...

Any general direction or recommendations appreciated! Cheers!

Joe


EXAMPLE INPUT DATA:
County Indlab Cnty1 Avg1
bench_val bench_cnty
Morgan % poverty 24 19
15 Wolfe
Morgan YPLL 11,135 8,572
6,510 Jefferson
Morgan GCPC 0.14 0.34 .
42 Boone

BASIC CODE:
ods pdf file="C:\kentucky_&county.pdf" style=BarrettsBlue
newfile=bygroup;
options nonumber nodate;
proc report data=fea.final nowindows headskip
style(report)=[preimage="c:\cprc-nichq4.gif " vjust=center];
*ods html note "Healthy Lifestyles in &county County, &state";
column grp indlab cnty1 Avg1 bench_val bench_cnty;
define grp/ order 'group' noprint;
define indlab / ' ' format=$50. missing order=data;
define cnty1 / "county" missing;
define Avg1 / 'State average' missing;
define bench_val / 'Best in state' missing;
define bench_cnty / ' ' format=$CHAR20. missing;
break after grp/skip;
by county;
run;
quit;
ods pdf close;

IDEAL REPORT:
http://docs.google.com/viewer?a=v&pid=sites&srcid=ZGVmYXVsdGRvbWFpbnxqb2Vzc2Fzc2l0ZXxneDo3NmY2NDgxNzc0MDBiODI

REPORT TO DATE USING PROC REPORT:
http://docs.google.com/viewer?a=v&pid=sites&srcid=ZGVmYXVsdGRvbWFpbnxqb2Vzc2Fzc2l0ZXxneDpjOTUzOGJlYjI3YmNkM2Q
From: joecool on
Many thanks Ya. Your advice and strategy will help a lot. I'll give
the backgroundimage= a shot, using conditional statements which select
images w/ different degrees filled in. Meanwhile, I'm still using proc
report just because I'm more comfortable w/ it. More to come...

Joe