What do you get when you run the following?...
goptions device=png;
axis1 label=(angle=90 font="albany amt" 'Here is a mu character: '
font="albany amt/unicode" '03bc'x font="albany amt" ' ' font="albany amt/unicode" '006d'x);
axis2 offset=(15,15);
symbol1 value=circle interpol=boxcti;
proc gplot data=sashelp.class;
plot height*sex / vaxis=axis1 haxis=axis2;
run;
Yep - it seems that maybe you've got an older version of SAS that had some quirks with angled y-axis text labels ... several small spacing issues were fixed in both 9.2 and 9.3. I would definitely recommend upgrading to 9.3 if possible!
In the meantime, perhaps one work-around is to not rotate the y-axis label. With such a short label, it would fit just as well non-rotated (and would be easier to read non-rotated). **This is the work-around I would recommend.
Another possible work-around might be to annotate the text for the y-axis label (if you really want it rotated). In the worst-case, you could annotate each character separately, and put them anywhere you want.
And, as ballardw mentioned, you could try the SAS/Graph 'greek' software font. The character won't be smooth/anti-aliased, but it's easier to get the spacing right with the software fonts:
goptions device=png;
axis1 label=(angle=90 font=swiss 'Here is a mu character: '
font=greek 'm' font=swiss ' m');
axis2 offset=(15,15);
symbol1 value=circle interpol=boxcti;
proc gplot data=sashelp.class;
plot height*sex / vaxis=axis1 haxis=axis2;
run;
All the characters in the SAS/Graph 'greek' software font can be found in a table on the following page:
Yes, this code worked, amazing!! :smileylaugh:
Just to be a little picky, different fonts in one label do not look as natural as if fonts are same. I still prefer to use the code you and danH provided at the first time. I will wait for my 9.3 :smileygrin:, Thanks guys, very helpful!!!
The left one is from the geek/swiss fonts combined (in this way, we can use a lot of special symbols); the right pic is from the "latin1-supplement" code (in this way we can have very limited symbol options)
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.
Ready to level-up your skills? Choose your own adventure.