I'm using PROC REPORT and outputting a pdf file using ODS. I want to preserve the blanks. For example, the 1 should be centered under Standard.
my output:
my footnote statements:
footnote1 height=9pt "Standard Grade 3 Grade 4–5 Grade 6 Grade 7 Grade 8";
footnote2 height=9pt " 1 Number Sense and Base Ten Number Sense and Base Ten The Number System The Number System The Number System";
Usage Note 23332: Keeping leading and trailing blank spaces in titles and footnotes using ODS shows how to modify the style template. I think you'll need to use a fixed width font to get the text to line up the way it's typed in the program editor.
* http://support.sas.com/kb/23/332.html shows how to update style
* template for HTML or RTF. similar logic for PDF. ;
proc template;
define style styles.modified_Pearl;
parent=styles.Pearl;
style systemfooter from systemfooter
"Style element responsible for footnotes" /
asis=on;
end;
run;
options orientation=landscape nodate;
* probably need to use fixed width font on footnotes to get text to line up
* as intended. ;
ODS PDF FILE='/folders/myfolders/ODS PDF/PDF with blanks preserved in footnotes.PDF'
style=modified_Pearl;
proc report data=sashelp.class nowd;
columns name age sex height weight;
footnote1 font=Courier height=9pt "Standard Grade 3 Grade 4–5 Grade 6 Grade 7 Grade 8 ";
footnote2 font=Courier height=9pt " 1 Number Sense and Base Ten Number Sense and Base Ten The Number System The Number System The Number System";
run;
ODS PDF CLOSE;
Screen shot of the footnotes with the blanks preserved in PDF
Usage Note 23332: Keeping leading and trailing blank spaces in titles and footnotes using ODS shows how to modify the style template. I think you'll need to use a fixed width font to get the text to line up the way it's typed in the program editor.
* http://support.sas.com/kb/23/332.html shows how to update style
* template for HTML or RTF. similar logic for PDF. ;
proc template;
define style styles.modified_Pearl;
parent=styles.Pearl;
style systemfooter from systemfooter
"Style element responsible for footnotes" /
asis=on;
end;
run;
options orientation=landscape nodate;
* probably need to use fixed width font on footnotes to get text to line up
* as intended. ;
ODS PDF FILE='/folders/myfolders/ODS PDF/PDF with blanks preserved in footnotes.PDF'
style=modified_Pearl;
proc report data=sashelp.class nowd;
columns name age sex height weight;
footnote1 font=Courier height=9pt "Standard Grade 3 Grade 4–5 Grade 6 Grade 7 Grade 8 ";
footnote2 font=Courier height=9pt " 1 Number Sense and Base Ten Number Sense and Base Ten The Number System The Number System The Number System";
run;
ODS PDF CLOSE;
Screen shot of the footnotes with the blanks preserved in PDF
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
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.
Ready to level-up your skills? Choose your own adventure.