score:1

The answer is on the d3noob page: the initial node location is arbitrarily determined by d3.js when you associate them with the links, i.e.

links.forEach(function(link) {
  link.source = nodes[link.source] || 
    (nodes[link.source] = {name: link.source});
  link.target = nodes[link.target] || 
    (nodes[link.target] = {name: link.target});
  link.value = +link.value;
});

I'm not too sure about the rest of your question though. Did you mean the tick function?

I think about it this way: at each tick, the x and y positions of all the links (and/or nodes ... not too sure) change, so you need to re-draw the paths and the circles according to the new x and y. How to re-draw those things depend on your tick function.


Related Query

More Query from same tag