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

Hello,

 

I would like to specify the order of the variables in the legend of a radar graph using proc gradar.  The default is alphabetical.  I know how this can be done when a group= option is available for some graphing procedures.  However, proc gradar uses an overlayvar= option for specifying graphing different groups of variables on the same plot.   Does anyone know how to do this?  My code is below.

 

goptions reset=all cback=white border htitle=12pt htext=10pt; 
proc gradar data=race;
chart descrip /freq=meanpct overlayvar=race_ethnicity lstars=(1 1 1 1 1)
cstars=(CX000000 CXDCDCDC CXFF0000 CX0000FF CX00FF00)
starfill=(empty solid empty empty empty) cstarcircles=ltgray cframe=white caxis=ltgray;
run;

 

Thank you -- Jessi Thomson

1 ACCEPTED SOLUTION

Accepted Solutions
4 REPLIES 4
ballardw
Super User

It has been a long time since I worked with Proc Gradar.

I think you may accomplish what you want by creating a numeric variable that has codes in the order you would like them displayed and then use a custom format to display the desired text for that variable.

JThomson21
Calcite | Level 5
Great - thank you. I will try your approach.


ballardw
Super User

It may also help to sort by that variable.

JThomson21
Calcite | Level 5
Your solution worked beautifully! Thank you so very much and have a wonderful day.


SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

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.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 828 views
  • 0 likes
  • 2 in conversation