BookmarkSubscribeRSS Feed
rhaley1821
Obsidian | Level 7

Hi all,

 

I am working on creating a graph that includes two lines of xaxis labels, one bolded and the second not. I am unsure how to selectively bold the first line in proc sgplot. I would appreciate any help. Thanks! 

 

graph I am attempting to produce: 

 

Screen Shot 2020-12-06 at 3.19.08 PM.png

 

current code: 

 

TITLE 'title1';
PROC SGPLOT DATA=work.test;
VBAR State / RESPONSE=Col
FILLATTRS=(color=blue);
XAXIS LABEL = 'State '
LABELATTRS=(WEIGHT=bold);
YAXIS LABEL='Percent'
LABELATTRS=(WEIGHT=bold)
GRID
VALUES=(0 to 4 by 1);
REFLINE 1.8 / AXIS=y
LINEATTRS= (COLOR=indigo pattern=dash)
LABEL='NA = 1.8'
LABELLOC=inside;
RUN;
TITLE;

 

Thank you!

2 REPLIES 2
PaigeMiller
Diamond | Level 26

While this may be possible using a single XAXIS statement, you could certainly create the second line which is un-bolded using a FOOTNOTE statement.

--
Paige Miller
rhaley1821
Obsidian | Level 7

That works perfectly, thank you so much! 

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!

Register now

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 962 views
  • 0 likes
  • 2 in conversation