Saturday, 15 August 2015

javascript - Possible to use a circle pack layout in d3.js with fixed circle sizes? -



javascript - Possible to use a circle pack layout in d3.js with fixed circle sizes? -

this circle pack layout illustration (http://bl.ocks.org/4063269) perfect project i'm working on, sizes circles relative 1 another:

is there simple way specify fixed radii each circle?

i've scoured source code, examples, google, , stackoverflow , can't seem find helpful.

the exact sizing of circles of import me.

it possible, , simple thing do. first reply accurate, believe mine simpler, more explicit, attaching too.

please take @ example: jsfiddle

when press "constant" button, see this:

the key code line this:

pack.value(function(d) { homecoming 100; })

this create circle radiuses constant regardles of data. 100 can constant of course. can apply line in circle pack initialization (most case), or reinitialization (like in example).

hope helps.

javascript svg d3.js circle-pack

No comments:

Post a Comment