Data visualization with SAS programming

Reducing the space between title and bar graph

Accepted Solution Solved
Reply
Contributor bts
Contributor
Posts: 23
Accepted Solution

Reducing the space between title and bar graph

I'm having trouble reducing the space between the top of my bar graph and the title. I have 6 graphs per page, and the move= statement (if that's the solution) is stumping me. I added "move=(0,-1) but that squished the size of table. I only need to remove about 0.5 inches of blank space. Below is my code for graph 1 of 6 (page title omitted):

 

 

goptions horigin=0 vorigin=6.75 hsize=3 vsize=3 htext=7pt htitle=9pt ftitle="bold" ;

axis1 label=(a=90 f="Albany AMT" "Frequency") order=(0 to 140 by 20) minor=none;

axis2 label=none value=none;

axis3 label=none ;

legend1

label=("Response" h=2 pt position=left j=c)

position=(top inside left) mode=share

value=(h=5 pt 'Yes' 'No');

pattern1 v=solid color=CX93BFBF;

pattern2 v=solid color=CX4791ED;

 

   proc gchart data=griffin_collapsed_values;

       vbar discuss_pay/DISCRETE

       INSIDE=PERCENT

       GROUP=gender

  SUBGROUP=discuss_pay

       RAXIS=axis1

  maxis=axis2

  gaxis=axis3

legend=legend1

space=0

width=6

  coutline=white;

where discuss_pay ne . and gender le 2;

format gender genderf. discuss_pay yesno.;

title1 "Gender" f="bold" ;

footnote1 j=c h=.75 f=Albany "Figure 1a. &chi1a";

    run;

    quit;

 

 


Accepted Solutions
Solution
‎04-13-2016 08:16 AM
Grand Advisor
Posts: 10,192

Re: Reducing the space between title and bar graph

You may want to consider moving to SGplot or SGpanel. The space between the titles and graphs is less and since you say you are attempting to put 6 charts to a page then, depending on your data, SGPanel may be a good option. Also the development by SAS is going towards the SG procedures.

View solution in original post


All Replies
Grand Advisor
Posts: 10,192

Re: Reducing the space between title and bar graph

Code without example data is hard to test.

Which destination are you sending this to? HTML, RTF, PDF and others may require different approaches. Also there are options related to destinations that specifically affect graph titles.

Which is your currently active ODS Style?

Contributor bts
Contributor
Posts: 23

Re: Reducing the space between title and bar graph

PDF - Here's the preceeding code: 

 

GOPTIONS RESET=ALL ftext="Albany AMT";

ods pdf file="\\vmware-host\Shared Folders\Documents\My Documents\\test3.pdf" startpage=never ;

goptions htitle=11pt;

options nodate nonumber;

options leftmargin=1in rightmargin=1in; 

proc gslide;

title1 'Q1: Did the medical team discuss payment with you?' lspace=.5in f="bold";

run;quit;

 

And thank you for your help!

Solution
‎04-13-2016 08:16 AM
Grand Advisor
Posts: 10,192

Re: Reducing the space between title and bar graph

You may want to consider moving to SGplot or SGpanel. The space between the titles and graphs is less and since you say you are attempting to put 6 charts to a page then, depending on your data, SGPanel may be a good option. Also the development by SAS is going towards the SG procedures.

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 3 replies
  • 357 views
  • 0 likes
  • 2 in conversation