D3 polyliner scale in partition tree
===

  I am using a Partition tree as in this [example][1] to try and make a visualization for taxonomy trees.  I tried to follow the code in the d3.js and the scripting in the html. It looks like the Layout and onclick event just increases the ’rect’ sizes and then clips it to fit in the same size SVG element.  Would it be possible to use a polylinear scale on the x axis so I can keep each parent nodes on screen as I go deeper into the tree?

 For example if the layout was 160px wide and four columns across each column is 40px wide.  I’d like the tree to start with the first column 10px wide which makes the others fill up the 150px at 50px each. If the next column was clicked then the domain and range would change so that the 2 left columns would be 10px each and the others would be 70px etc.

I tried changing the range from ([0, 160]) to ([0, 10, 160]) and the domain to ([0, .25 ,1]).  Is this the right approach? The positions changed but not the widths. I would probably want to change the range and domain depending on the depth.


  [1]: http://mbostock.github.com/d3/talk/20111018/partition.html