I have been playing about with the code for a d3 sunburst chart/diagram from this site.
I've been searching for tips on how to change the degree of the sunburst from 360 to another value (probably 220) and to make it not a complete circle by only showing 2 sets of data. Example image:
Can someone please point me to a tutorial showing how to achieve this more-than-semi circle?
d3.partition().size([2 * Math.PI, radius]);
uses a width of 360 degrees (2π) which is used to set d.x1, d.x0, both of which are then used as start and end angles. Just use2π*220/360
as the width value of the partition. The explanation in the link has some details - for example with a semi circle. (d3.partition().size()
takes an array of the form: [width,height]) – Andrew Reid