Date: Wed, 5 Sep 2007 12:45:50 -0400
Reply-To: Ya Huang <ya.huang@AMYLIN.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Ya Huang <ya.huang@AMYLIN.COM>
Subject: Re: More Colors and Proc Print
Check out this list:
http://v8doc.sas.com/sashtml/gref/zgscheme.htm
proc format;
picture bgcolor 3 = 'Green'
2 = 'Yellow'
1 = 'Red'
4 = 'Gray'
5 = 'LIYBR' /* 5='CXA69F7A' */
;
run;
data tempdata;
length Q1 $15;
input Site Q1 $ evaltot_Sum Red Amber Green;
cards;
3 Cleanliness 2 4 2 5
...
I'm suprised that 5='CXA69F7A' doesn't work! LIYBR is "light yellowish
brown" :-)
On Wed, 5 Sep 2007 07:56:04 -0700, webonomic <webonomic@GMAIL.COM> wrote:
>I have some test code below. I am doing a traffic light type of
>approach and trying to color the background of the appropriate cell.
>All is working well but I'd like to be able to use colors that don't
>seem available to me.
>
>Is there a way to use RGB or Hexidecimal colors or something else? Or
>a way to make more colors available to the system?
>
>
>I am using the following code:
>
>data tempdata;
>length Q1 $15;
>input Site Q1 $ evaltot_Sum Red Amber Green;
>cards;
>3 Cleanliness 2 4 2 4
>3 Friendliness 3 4 4 3
>3 Responsiveness 3 4 4 3
>3 Condition 3 4 4 3
>3 Safety 3 4 4 3
>4 Cleanliness 1 1 4 4
>4 Friendliness 3 4 4 3
>4 Responsiveness 3 4 4 3
>4 Condition 3 4 4 3
>4 Safety 3 4 4 3
>9 Cleanliness 2 4 2 4
>9 Friendliness 3 4 4 3
>9 Responsiveness 3 4 4 3
>9 Condition 3 4 4 3
>9 Safety 1 1 4 4
>;
>run;
>
>proc format;
>picture bgcolor 3 = 'Green'
> 2 = 'Yellow'
> 1 = 'Red'
> 4 = 'Gray';
>run;
>
>ods html;
>proc print data = tempdata noobs label;
>var Q1;
>var Red / style={background=bgcolor.};
>var Amber / style={background=bgcolor.};
>var Green / style={background=bgcolor.};
>by Site;
>label Red='R' Amber='A' Green='G' Q1='Services and Facilities';
>run;
>ods html close;