BookmarkSubscribeRSS Feed
lueryy2000
Calcite | Level 5
Hi,

I posted a similar question before, the feedback are valuable. But I still don't get the right answer I want, this time I am more focus on getting rid of the second node of the pie chart, which is "pie chart of group" for my data. Please let me know if this is workable in SAS. Thanks! Below is my data and code.

data mydata;
input group $ count percent;
datalines;
A 20 .2
B 30 .3
C 50 .5
;
run;

ods pdf file='H:\report.pdf';
PROC GCHART DATA=mydata;
PIE group / sumvar=count ;
RUN;
ods pdf close;
6 REPLIES 6
Cynthia_sas
SAS Super FREQ
Hi:
Usually PROC GCHART needs a QUIT statement after the RUN statement. Does your PDF file contain any output???? Or, did you post incomplete code?

cynthia
ArtC
Rhodochrosite | Level 12
What exactly do you not want to accomplish? Do you need to exclude GROUP='B' from the chart?
lueryy2000
Calcite | Level 5
Sorry to confuse. ods pdf generated two bookmarks for proc gchart here, the first node is "The Gchart Procedure", and the second is "pie chart of group". I just want to keep the first one and eliminate the second one. Thanks.
Lu
Cynthia_sas
SAS Super FREQ
Hi:
As indicated in my previous response, your choices are to:
1) use ODS PROCLABEL to alter the default text or blank out the text for the top level node
2) use DESCRIPTION to alter the default text or blank out the txt for the second level node
(Neither of these options will eliminate the node completely)
OR
3) use ODS DOCUMENT to rearrange the structure of the bookmarks, so there is only 1 bookmark for each graph.

SAS/GRAPH works a bit differently with bookmarks than tabular output. So the only way to eliminate nodes completely, would be to use ODS DOCUMENT. However, I believe that there is one node in ODS DOCUMENT for SAS/GRAPH that you cannot change -- and I think it is the second level node. So, you might be able to get rid of the top level node in the ODS DOCUMENT, but you would still have the second level node with the original name, when you replayed. This would at least give you one node per graph.

You may want to work with Tech Support on this question, because this is going to require that they look at ALL your code and help you come up with a solution that's satisfactory, if possible. If for example, you were putting 2 graphs on 1 page and only wanted to have 1 bookmark node per "page", I do not believe that you could eliminate the second level nodes for the graph output.

To open a track with Tech Support, open a track by filling out this form:
http://support.sas.com/ctx/supportform/createForm

cynthia
lueryy2000
Calcite | Level 5
Thank you for your thorough explanation. As you said, I tried ods document and got no idea how to get rid of the second node for the pie chart. I might contact sas tech to see if they can help.

Thanks again!
Lu
Cynthia_sas
SAS Super FREQ
As I explained, you may have to live with getting rid of the top node and keeping the second node. But Tech Support is probably your best resource on this question.

cynthia

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
  • 6 replies
  • 931 views
  • 0 likes
  • 3 in conversation