title: Direction of link orientation in tree diagram incorrect
body: <p>Starting from the tree diagram example <a href="http://bl.ocks.org/d3noob/8323795" rel="nofollow noreferrer">here</a> I want to change the links so that the source and target locations of each can be altered relative to their common meeting point. My current progress point is <a href="http://bl.ocks.org/d3noob/7fa9ce06684669b5a7964b928f11043d" rel="nofollow noreferrer">here</a> (these examples are contrived to demonstrate the problem, but I believe it does so adequately).</p>
  
  <p>This appears to be possible using the <a href="https://github.com/d3/d3-3.x-api-reference/blob/master/SVG-Shapes.md#diagonal_source" rel="nofollow noreferrer">source</a> and <a href="https://github.com/d3/d3-3.x-api-reference/blob/master/SVG-Shapes.md#diagonal_target" rel="nofollow noreferrer">target</a> assessor functions. I have therefore edited the original code for the <code>diagonal</code> variable from;</p>
  
  <pre><code>var diagonal = d3.svg.diagonal()
      .projection(function(d) { return [d.y, d.x]; });
  </code></pre>
  
  <p>to;</p>
  
  <pre><code>var diagonal = d3.svg.diagonal()
      .source(function(d) { return {x: d.source.y , y: d.source.x}; })
      .target(function(d) { return {x: d.target.y , y: d.target.x}; });
  </code></pre>
  
  <p>Which has worked fine for the locations, but the links think that they are still vertical and as a result look like this;</p>
  
  <p><a href="https://i.stack.imgur.com/50zlq.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/50zlq.png" alt="enter image description here"></a></p>
  
  <p>rather than this;</p>
  
  <p><a href="https://i.stack.imgur.com/QueM8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/QueM8.png" alt="enter image description here"></a></p>
  
  <p>I have tried altering the orientations of the x / y values in the diagonal variable declaration which only succeeds in orientating the tree links vertically.</p>
  
  <p>I have also tried doing the same in a slightly more complex piece of code when entering the links, with the links appearing with the incorrect orientation again. </p>
  
  <p>I can't help but think that I need to be including an additional assessor to account for the direction of the curve, but I'm darned if I can see it.</p>
  
  <p>Starting code <a href="http://bl.ocks.org/d3noob/8323795" rel="nofollow noreferrer">here</a>.</p>
  
  <p>Adapted code <a href="http://bl.ocks.org/d3noob/7fa9ce06684669b5a7964b928f11043d" rel="nofollow noreferrer">here</a>.</p>
  
  <p>Many thanks for you attention.</p>