BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Bruce123
Calcite | Level 5

Hello

I have a graph generated from sas and I am looking to make it fill more of the pdf document, which it is presented in.

I have attacted the file, and would like it to fil more of the doucment, since there is a lot of empty space.

But I am not quite sure on how to do so, so I was hoping for some help.

Here is the relevant code:

OPTIONS ORIENTATION=LANDSCAPE NODATE nobyline; /*nobyline fjerner automatisk genereret by linie*/

ODS PDF File = "F:xx.pdf "  STYLE=sasWeb;

proc sgplot data=Have;*noautolegend;

hbar NodeName / response=Variable/*stat=sum*/ nostatlabel datalabel

        discreteoffset=-0.2 barwidth=0.4 fillattrs=(color=VIGB) name="A";

hbar NodeName / response=AfkastATD_BM /*stat=sum*/ nostatlabel datalabel

           discreteoffset=+0.25 barwidth=0.4 fillattrs=(color=VLIYG) name="B";

yaxis grid label='Aktiver' values=(1 to 10 by 1);

keylegend "Afkast" "BM" /across=2  down=1 location=outside  position=topleft title="" ;

label AfkastATD_NodeName = "A"

AfkastATD_BM = "B";

TITLE FONT='Times' BOLD COLOR=BLACK HEIGHT=1.5 "xxx ";

run;

TITLE; FOOTNOTE;

GOPTIONS RESET=ALL;

ODS PDF CLOSE;

1 ACCEPTED SOLUTION

Accepted Solutions
RW9
Diamond | Level 26 RW9
Diamond | Level 26

Hi,

You can set the size of a graph in the ods graphics options:

ods graphics / reset=all height=10cm width=50cm noborder;

options orientation=landscape;

In the above I use cm, but you can use various different measurements.

View solution in original post

2 REPLIES 2
RW9
Diamond | Level 26 RW9
Diamond | Level 26

Hi,

You can set the size of a graph in the ods graphics options:

ods graphics / reset=all height=10cm width=50cm noborder;

options orientation=landscape;

In the above I use cm, but you can use various different measurements.

Bruce123
Calcite | Level 5

Hey

Thanks, your suggestion solved my problem.

Thank you for your help Smiley Happy

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 1002 views
  • 0 likes
  • 2 in conversation