I'm using ODS EXCEL to export results produced by PROC FREQ to Excel. The output includes an empty row between the table title and the start of the table (see highlighted in yellow in Excel file). How can I delete that row in my SAS code?
Do I do this in the PROC TEMPLATE or in the ODS EXCEL statement?
Here's my sample code:
*Create sample dataset;
data test;
set sashelp.Class;
run;
*Create template;
proc template;
edit base.freq.onewaylist;
edit FVariable;
just=varjust;
style=rowheader;
header="Age at survey date";
end;
end;
run;
ods excel file="PATHNAME\test.xlsx"
options(sheet_name="Female"
embedded_titles="yes"
embed_titles_once="yes");
proc freq data = test(where=(sex="F"));
tables age;
title "Age at survey for female participants";
run;
ods excel close;
proc template;
delete base.freq.onewaylist;
run;
Thank you!
Thanks! I want to delete it, not just hide it.
How would I do this in PROC TEMPLATE?
Thanks! I will delete it in Excel for now and then look more closely at the proc template code.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.
Find more tutorials on the SAS Users YouTube channel.