Date: Tue, 21 Oct 2008 10:32:55 -0500
Reply-To: Mary <email@example.com>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Mary <mlhoward@AVALON.NET>
Subject: How to do conditional formatting in SAS?
Content-Type: text/plain; format=flowed; charset="iso-8859-1";
I've got output that I'm generating that shows a number of columns, one of
which is the change in eye vision (these are changes in logmar scores), and
my logmar scores look like this:
I'm using Excel tagsets to write these out to an XML file and to import into
Right now I'm using Proc Print within an Excel tagset wrapper.
ods listing close;
ods tagsets.excelxp file='C:\Work_Activities\results_sheetnames.xml'
ods tagsets.excelxp options(sheet_name="&sheetname");
proc print noobs label data=results;
ods tagsets.excelxp close;
I would like to add conditional formatting to the column of the change in
logmar scores; such as to change the background color to yellow or something
when the value is out of a certain range (such as when the value is > .25).
Is there a way that I can add conditional formatting on this column via Proc
Report or something else and then output that to XML using Excel tagsets? I
anticipate rerunning this a number of times as we update values, and thus
would like to program in the conditional formatting into my SAS program
rather than adding it once I pull the output into Excel.