end;
define crosstabs Base.Freq.CrossTabFreqs;
notes "Crosstabulation table";
style=table {backgroundcolor=#BFCFFF};
cell_style=data {backgroundcolor=#FFFFF0};
row_var_style=rowheader {backgroundcolor=#BFCFFF color=rowfg.};
col_var_style=header {backgroundcolor=#BFCFFF color=colfg.};
row_total_style=data {backgroundcolor=#F0F0F0};
col_total_style=data {backgroundcolor=#F0F0F0};
grand_total_style=datastrong {backgroundcolor=#F0F0F0};
legend_style=header {backgroundcolor=#BFCFFF color=#6078bf fontstyle=italic};
rows_header=RowsHeader cols_header=ColsHeader;
label = "Frequency Counts and Percentages";
define header TableOf;
text "Table of " _ROW_LABEL_ " by " _COL_LABEL_ / _ROW_LABEL_ ^= ''
& _COL_LABEL_ ^= '';
text "Table of " _ROW_LABEL_ " by " _COL_NAME_ / _ROW_LABEL_ ^= '';
text "Table of " _ROW_NAME_ " by " _COL_LABEL_ / _COL_LABEL_ ^= '';
text "Table of " _ROW_NAME_ " by " _COL_NAME_;
style=header {backgroundcolor=#BFCFFF color=#6078bf fontstyle=italic};
end;
define header RowsHeader;
text _ROW_LABEL_ / _ROW_LABEL_ ^= '';
text _ROW_NAME_;
style=header {backgroundcolor=#BFCFFF color=#6078bf fontstyle=italic};
space=0;
end;
define header ColsHeader;
text _COL_LABEL_ / _COL_LABEL_ ^= '';
text _COL_NAME_;
style=header {backgroundcolor=#BFCFFF color=#6078bf fontstyle=italic};
space=1;
end;
define header ControllingFor;
dynamic StratNum StrataVariableNames StrataVariableLabels;
text "Controlling for" StrataVariableNames / StratNum > 0;
style=header;
end;
define footer Missing;
dynamic FMissing;
text "Frequency Missing = " FMissing -12.99 / FMissing ^= 0;
style=header {backgroundcolor=#BFCFFF color=#6078bf fontstyle=italic};
space=1;
end;
define footer NoObs;
dynamic SampleSize;
text "Effective Sample Size = 0" / SampleSize = 0;
space=1;
style=header;
end;
Examples from the Gallery of ODS Samples 1065

Get SAS 9.4 Output Delivery System, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.