I'm not sure if this is an answer (I think it is) or I should post this as a comment BUT here's the thing with your code:

d3.hierarchy() looks for an object with "name" and "children" and manipulates the data which is then used by partition(root).

If you debug the code at, you'll see that d3.hierarchy() receives an object as {name: "flare", children: Array[15]}

In your code, if I just wrap the data array in an object, say: {name: "test", children: data}, it creates a sunburst with colors and appropriate titles.

Here's a FIDDLE with the changes. (btw I've commented arrayToObject)

Hope this helps. :)

Related Query

More Query from same tag