I am new to d3 and currently working on the Icicle layout example. I have 2 questions:
- Is it possible to have multiple top-level nodes in this example? In other words, instead of a single top-level node of "flare", can we have 3 top-level nodes ("flare1", "flare 2" and "flare 3"), which can then have their respective children nodes? I have tried importing the json data as an array of objects but that did not work.
If it is not possible to have multiple top-level nodes, how can I hide the root node ("flare") so that the 2nd level nodes ("vis", "util", "animate") appear to be top-level nodes?
- How can we sort the nodes (on a particular level) based on their position in the json file, rather than their size? In other words, how can we sort the second level nodes in the above example so that they appear (from left to right) in the order of "analytics", "cluster", "graph" and so on (their order in json file); instead of their current order ("vis", "util", "animate", etc.).