0

I have a d3 stacked column and for the way I'm doing this viz it makes sense to add a separation (effectively a white line) between each element in the stacked column. Is there an easy way to do this on the Y axis with padding? The other way I can think of would be to add tiny blocks in between each column element, but that seems tedious.

Thanks for any advice. PS I'm using d3 V4.

ouonomos
  • 700
  • 1
  • 9
  • 25
  • 1
    do the rects you're using for the stack already have a stroke (outline)? if not, you could use a one-sided stroke using dashes, like here http://stackoverflow.com/questions/8976791/how-to-set-a-stroke-width1-on-only-certain-sides-of-svg-shapes – danimal Sep 15 '16 at 11:40
  • Thanks, I'll consider this! – ouonomos Sep 15 '16 at 19:12

1 Answers1

0

The answer that @danimal is giving would work, I think. However, in the end I went with "injecting" rows of empty rectangles. You can see the solution here: http://bl.ocks.org/mgoold/88f6f798dac245b3261ed1a543b04415 .

The only thing with doing it this way is that a y axis ceases to make sense. So I had to do left side call-outs for the volume amts instead.

HTH

ouonomos
  • 700
  • 1
  • 9
  • 25