0

So I have seven different fields/variables in a SAS table each containing 1's and 0's. I need to - if at all possible - display these seven variables in one single pie. Is this possible? If so how? When I do this: pie variable1 variable2 / options I get two pies. Is there a way for me to combine them into one?

1 Answers1

0

If your indicators reflect percentages of a whole WITHOUT overlap then yes you can.

This applies to multiple choice questions where you can select One of the Above. If it's a question that is select All that apply, then this would not be appropriate.

You cannot use the GCHART procedure but first need to summarize your data. Use a proc means to calculate the sums and then pass those to your PROC.

Proc means data = have stackods sum;
VAR ind1-ind7;
ODS OUTPUT summary=totals;
 Run;

Use the TOTALS dataset in your gchart with the sum as the Pie statement. I don't recall what the variable is called.

Reeza
  • 20,510
  • 4
  • 21
  • 38