BookmarkSubscribeRSS Feed
deleted_user
Not applicable
I would like to increase the width of the bars.
bu1 has two categories and question has 4 categories (8 bars).
I've tried changing the width and space, but I keep getting this warning:
WARNING: There was not enough room to use the specified width of 10 for the bars.

Does anyone know how to get around this problem and increase the width of the bars?

proc gchart data=bar1 anno=my_anno1;
hbar bu1 / discrete
nostats
type=sum sumvar=catpct
group=question
subgroup=qs
autoref clipref cref=graycc
maxis=axis1
raxis=axis2
width=10
legend=legend1
coutline=black
/*space=15*/
1 REPLY 1
GraphGuy
Meteorite | Level 14
This one's hard to answer exactly, without having the data to experiment with, but here are a couple of ideas ...

Perhaps you could make the entire chart taller (such as using "goptions ypixels=1000"), which would give more room for wider bars.

Perhaps try changing the device (there might be slight differences in bar spacing between dev=gif and dev=png, and there will certainly be differences with dev=actximg and dev=javaimg).

And if the values along the bottom/response axis of your hbar chart have a format applied, and if that format 'pads' on a lot of extra space on the left (such as if you're using the "comma20." format, when your numbers only need 4 or 5 digits), then you might try using a smaller format to free up some space to be used by wider bars in the bar chart.

These are just some ideas - not really sure if any of them will be your "silver bullet" though! :) Message was edited by: Robert Allison @ SAS

sas-innovate-white.png

Special offer for SAS Communities members

Save $250 on SAS Innovate and get a free advance copy of the new SAS For Dummies book! Use the code "SASforDummies" to register. Don't miss out, May 6-9, in Orlando, Florida.

 

View the full agenda.

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 1 reply
  • 2007 views
  • 0 likes
  • 2 in conversation