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

Folks -

 

Trying to rotate/change the orientation of the y-axis label, for example - I want the label="hour' to show up on plot like 

 

H

o

u

r

 

I'm a fairly new SAS user, so thanks for any help I can get.  I've read all the documentation I could find, but not helpful. Figure the SAS PROs can help me out. 

 

Regards!

1 ACCEPTED SOLUTION

Accepted Solutions
Rick_SAS
SAS Super FREQ

No, PROC SGPLOT does not support that option (which is sometimes called "Hotel Text") for the label.

The best I can offer is to suppress the label by using 

yaxis display=(nolabel);

and then use SG annotation to manually stack the letters for the vertical label.

View solution in original post

6 REPLIES 6
ballardw
Super User

Please show the code the you are currently using to create your plot. Depending on the individual procedure the are different ways and we need to know the procedure and current options.

Ksharp
Super User

Post it at a better place :

Graphics Programming

forum

ChrisNZ
Tourmaline | Level 20

With SAS/Graph you can use the rotate= and angle= options.

Moved to the graphics steam.

 

MarkHiltbruner
Fluorite | Level 6

All -

 

Here's the source -

 

PROC SGPLOT;
BY SMF70STN YEAR MONTH;
HBAR hour/RESPONSE=lpctby
DATALABELATTRS=(FAMILY='Georgia' SIZE=8pt COLOR=red weight=bold)
DATALABEL DATASKIN=crisp
BASELINEATTRS=(THICKNESS=0)
BARWIDTH=1
FILLATTRS=(COLOR=cadetblue);
format lpctby percent8.2;
TITLE;
TITLE1 H=2.0 C=BLACK 'BIT AVERAGE LPAR USAGE';
TITLE2 H=1.5 C=BLACK 'LPAR NAME = ' C=RED ' #BYVAL1';
TITLE3 H=1.5 C=BLACK 'FOR ' C=RED ' #BYVAL3' ' / ' '#BYVAL2';
xaxis offsetmin=0 label='LPAR*Logical*Percent*Busy'
labelattrs=(size=12pt family=arial color=red weight=bold);
yaxis offsetmin=.02 offsetmax=.02
label='Hour' values= (0 to 23 by 1)
labelattrs=(size=12pt family=arial color=red weight=bold)
valueshint;
run;

 

Regards, Mark

Rick_SAS
SAS Super FREQ

No, PROC SGPLOT does not support that option (which is sometimes called "Hotel Text") for the label.

The best I can offer is to suppress the label by using 

yaxis display=(nolabel);

and then use SG annotation to manually stack the letters for the vertical label.

MarkHiltbruner
Fluorite | Level 6

Hi Rick -

 

Thanks for the response,  and yes, I was hoping for an easier solution.

 

Mark

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

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
  • 6 replies
  • 2565 views
  • 1 like
  • 5 in conversation