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

We have the following data:

ColorPerson
RedJohn
RedBill
RedBill
YellowJohn
YellowJohn
GreenJohn
GreenJohn
GreenSally
GreenBill
Blue

Sally

BlueBill

I'd like to create a donut chart where the outer slices represent the frequencies of the colors.

The inner donut should show the frequencies of the people within each color.

I've tried the Donut graph using Proc Gchart with color as the main variable and with subgroup=person, but that created a lot of concentric circles.  Any idea how I would set things up so there are only two rings?

1 ACCEPTED SOLUTION

Accepted Solutions
jakarman
Barite | Level 11

I think this sample is like your question 25522 - Subgroup a donut or pie chart using PROC GCHART

I am convinced Eguide should do the job also but the naming and word can be misleading for first time use.
You have used the "BY" statement this statement is commonly used for processing large datasets and wanting to split up the logical process/report as it where segregated datasets. By that able generating a flood of them.
Your question seems to me about grouping the data. 

---->-- ja karman --<-----

View solution in original post

5 REPLIES 5
jakarman
Barite | Level 11

tried Eguide?

---->-- ja karman --<-----
k9rescue
Calcite | Level 5

Yes, this is using EG. 

jakarman
Barite | Level 11

Use the EG approach selecting the the options/sample you are liking ... mouse klik-klik and you can view the generated code.
No need to invent that by yourself. And when ready you can still pick up the gplot code.

---->-- ja karman --<-----
k9rescue
Calcite | Level 5

That would be ideal. Unfortunately, my version of the EG doesn't do multi tiered pies.  So, I used custom code from it.

As per the original message - when I used those options with the pie graph, I got many consecutive circles.

jakarman
Barite | Level 11

I think this sample is like your question 25522 - Subgroup a donut or pie chart using PROC GCHART

I am convinced Eguide should do the job also but the naming and word can be misleading for first time use.
You have used the "BY" statement this statement is commonly used for processing large datasets and wanting to split up the logical process/report as it where segregated datasets. By that able generating a flood of them.
Your question seems to me about grouping the data. 

---->-- ja karman --<-----

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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
  • 5 replies
  • 801 views
  • 0 likes
  • 2 in conversation