Flat hierarchy -> Treemap/Sunburst Chart

jahsquare

Board Regular
Joined
Jan 22, 2014
Messages
51
Hi, I have hierarchical data in a named range "Table1" that looks like below, where the "Count" is the value for each Category, and The "Cumulative Count" is the sum of the current level and all child levels. Is there a way to quickly get this into a format to use the Treemap or Sunburst plots?

It would be amazing if I could do it withoug using the Cumulative Count column as generating that column on my dataset (250k records) requires an expensive calculation. The solution here looks close but doesn't quite get the format for the charts.

As a further step I would really like there to be a dynamic range (on another sheet) where I could enter e.g. "A" into a cell and the output range & chart would update automatically with the sub-categories starting with "A".

CountCumultative CountLevelCategory Name
25A1
27A2
228A3
105A4
57A5
558A6
57A7
58A8
559A9
35B1
27B2
28B3
19B4
1110B5
19B6
110B7
1111B8
17B9
18B10
119B11

<tbody>
</tbody>


Thanks for any insight.
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
* I can't figure out how to edit my post but the input data should have A, B, and C categories


CountCumultative CountLevelCategory Name
25A1
27A2
228A3
105B1
57B2
558B3
57B4
58B5
559A6
35C1
27C2
28C3
19C4
1110C5
19C6
110C7
1111C8
17C9
18C10
119C11

<tbody>
</tbody>


So for a Sunburst the output table would look like this:

L5L7L8L9L10L11Count
A1A2A32
B1B2B35
B4B5B65
C1C2C3C4C51
C6C7C81
C9C10C111

<colgroup><col style="width:48pt" span="7" width="64"> </colgroup><tbody>
</tbody>


And the plot would look like this: https://imgur.com/NcH6g0s
 
Upvote 0

Forum statistics

Threads
1,215,657
Messages
6,126,062
Members
449,286
Latest member
Lantern

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top