BookmarkSubscribeRSS Feed
ciro
Quartz | Level 8

hello,

I would like to learn a way to draw a tree graph as the one attached.

As you can see the first node represents a total and the other child nodes various subtotals.

I would have the possibility:

  1. to label each node (e.g Total1, Subtotal1,Subtotal2 etc..)
  2. To add a value for  the variable in each node
  3. To add another variable which represents the share of the variable over the overall total.
  4. To have each form colored, possibly based on a palette of colors

 

So there are two issue:

  1. how the dataset should be designed?
  2. are there procedures to draw such a graph?

 

Any suggestions, tips, codes are greatly appreciated

 

thank you very much in advance

1 REPLY 1
Rick_SAS
SAS Super FREQ

the tree (without labels) is called a dendrogram. Here is an example of how to use the DENDROGRAM statement in the Graph Template Language (GTL).

 

I don't have an opinion about the best way to add the labels. Others will offer their advice.

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
  • 1 reply
  • 525 views
  • 0 likes
  • 2 in conversation