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

Hi guys,

 

I am using gplot to graph my experience data, with x-axis ranger from -1 to 22 by step of 1. Everything work out nicely, however one problem is that I only have limited space across a-axis. for example for double digits number 10, 11, 12... the number is displayed vertically like:

1 1 1

0 1 2

So I am asking how do I make the font smaller that I can fit in all the values horizontally.

 

Thanks.

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
GraphGuy
Meteorite | Level 14

Here's how to control the font height of the tickmark values along an axis, in gplot:

 

axis1 value=(height=1.0pct);

 

proc gplot data=sashelp.class;
plot height*weight / haxis=axis1;
run;

 

View solution in original post

3 REPLIES 3
Reeza
Super User

You should use SGPLOT instead of GPLOT, then add an XAXIS statement and you can specify the values a little easier. I would recommend skipping every other one instead of changing the font.

 

xaxis values = (-2 to 22 by 2);

 

GPLOT is part of SAS/GRAPH and fairly old, the graphics are not as nice and it's harder to work with, which is why I recommend SGPLOT instead.

 


@ljr4616 wrote:

Hi guys,

 

I am using gplot to graph my experience data, with x-axis ranger from -1 to 22 by step of 1. Everything work out nicely, however one problem is that I only have limited space across a-axis. for example for double digits number 10, 11, 12... the number is displayed vertically like:

1 1 1

0 1 2

So I am asking how do I make the font smaller that I can fit in all the values horizontally.

 

Thanks.

 

 

 


 

PGStats
Opal | Level 21

Look what SGPLOT does in this simple example (version 9.4 TS Level 1M5) :

 

proc sgplot data=sashelp.heart;
vbox diastolic / category=ageAtStart;
run;

SGPlot1.png

 

PG
GraphGuy
Meteorite | Level 14

Here's how to control the font height of the tickmark values along an axis, in gplot:

 

axis1 value=(height=1.0pct);

 

proc gplot data=sashelp.class;
plot height*weight / haxis=axis1;
run;

 

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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
  • 3 replies
  • 1087 views
  • 1 like
  • 4 in conversation