☑ This topic is solved.
Need further help from the community? Please
sign in and ask a new question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Posted 01-18-2023 07:48 AM
(852 views)
I want the ods pdf to have gridded layout.
In the sas studio window it appears gridded, but the pdf has only 1 column.
Furthermore the print includes a first title statement that shouldn't appear because the #byval1 is not resolved yet.
data cars;
set sashelp.cars;
by model notsorted;
if first.model;
run;
proc transpose data=cars out=cars_long;
by model notsorted;
var _numeric_;
run;
data cars_long;
set cars_long;
label col1="value of analyzed variable" _name_="variable";
run;
proc sort data=cars_long;
by _name_;
run;
options papersize=A4 orientation=portrait leftmargin=1cm rightmargin=1cm;
title;
ods pdf file="/caslibs/marketing/__test.pdf" style=Style.MySasWeb nogfootnote nogtitle ;
options nobyline;
ods layout gridded columns=2 advance=bygroup;
title "Histogram & kernel for #byval1";
ods region;
proc sgplot data=cars_long noautolegend;
where col1 ne .;
by _NAME_ ;
histogram col1 / dataskin=sheen ;
density col1 / type=kernel transparency=0.4;
run;
options byline;
ods layout end;
ods pdf close;
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I don't know why your titles aren't working properly, this seems like a bug to me.
Your plots use the default size. If you change the plot size, then they will fit on one page.
ods graphics / height=3in width=3in;
or you can use any other height and width that works for you.
--
Paige Miller
Paige Miller
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I don't know why your titles aren't working properly, this seems like a bug to me.
Your plots use the default size. If you change the plot size, then they will fit on one page.
ods graphics / height=3in width=3in;
or you can use any other height and width that works for you.
--
Paige Miller
Paige Miller