Is there a way to apply color format to an entire row? Specifically, I have a table and using PROC TABULATE I wish to highlight the entire "Total" row at the bottom to make it stand out. I can highlight the cell labeled "Total" but cannot figure out how to color the rows of data next to it.
This link shows a number of ways to do banding in proc tabulate: http://support.sas.com/kb/25/401.html
And this link shows a solution closer to what you ask: https://communities.sas.com/t5/ODS-and-Base-Reporting/Format-Total-all-differently-in-Proc-Tabulate/...
You can may your table statements easier to read by using LABEL statements or KEYLABEL if the label text for you ALL will be the same(or mostly the same). Then you reduce the number ='xxxxxxxx' in the table.
Thanks for those resources, the <Parent> feature for customizing across rows is helpful but I'm having difficulty find examples of how to employ it on the All or Total rows within my table. I understand how to do it for a variable but not how to attached it to those calculation rows. These rows don't exist in my original data table, they are the result of the PROC TABULATE.
It might help to show the code you are using as there are some interactions between column on row that my be involved.
style=<parent> is likely what you are looking for but where to place it depends on the code you are using.
Sure below is my code sample
PROC TABULATE FORMAT= COMMA10.0 DATA = admit_accepted;
CLASS Event_Type Event_Name Event_Date Entry_Term_2;
VAR Attended Admitted Offer_Accepted Enrolled;
TABLE Event_Type='Event Type' * ((Event_Name='Event Name' * ((Event_Date=' ' * Entry_Term_2=' ') All = {Label ='Total (ALL)' style = {background = #90D9D7 }}))All = {Label = 'Total (ALL)' style = {background = #4d7ebf}}), Attended = 'Attended Event' Admitted Offer_Accepted='Offer Accepted' Enrolled;
FORMAT Entry_Term_2 $term_order.; **Term order format just puts in numerical order by entry term
TITLE 'Prospective/Yield Event Admissions Funnel';
KEYLABEL N=' ' SUM= ' ';
run;
This gives me the following out put but I want the "ALL" columns to be highlighted across the rows of other variables
This link shows a number of ways to do banding in proc tabulate: http://support.sas.com/kb/25/401.html
And this link shows a solution closer to what you ask: https://communities.sas.com/t5/ODS-and-Base-Reporting/Format-Total-all-differently-in-Proc-Tabulate/...
You can may your table statements easier to read by using LABEL statements or KEYLABEL if the label text for you ALL will be the same(or mostly the same). Then you reduce the number ='xxxxxxxx' in the table.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.