Hi,
I have the following SAS codes for proc tabulate:
TITLE j=left "Jadual 5.1: Jumlah penduduk mengikut taraf perkahwinan, kumpulan umur, jantina dan negeri, Malaysia, 2010";
Title2 font=bold italic j=left "Table 5.1: Total population by marital status, age group, sex and state, Malaysia, 2010";
title3 j=left " ";
title4 j=left "Jumlah:Malaysia";
Title5 font=bold italic j=left "Total";
ods escapechar='^';
proc tabulate data=work.table5dot1 class AGE_GROUP GENDER Marital_status1;
var ID;
table (GENDER={LABEL=' '} ALL='Grand Total') * (AGE_GROUP={LABEL=' '}
ALL='Jumlah ^S={font_style=italic}/ Total'),
ALL='Jumlah ^S={font_style=italic}/ Total'
Marital_status1='Taraf Perkahwinan
^S={font_style=italic} / Marital status' /
Box='Jantina dan kumpulan umur ^S={font_style=italic} / Sex and age group';
keylabel N=' ';
run;
This gives me the following result:
However, I need the line separator for the body of the table to be eliminated and only two lines should be there for the heading as per the following table.
'
Could anyone please help me to format this in order to get the output as the above table.
Thank you.
Set line color to white in style(header) for those you do not want to see:
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.