quadtree.y()

quadtree.y([y])

If y is specified, sets the current y-coordinate accessor and returns the quadtree. If y is not specified, returns the current y-accessor, which defaults to:

function y(d) {
  return d[1];
}

The y-acccessor is used to derive the y-coordinate of data when adding to and removing from the tree. It is also used when finding to re-access the coordinates of data previously added to the tree; therefore, the x- and y-accessors must be consistent, returning the same value given the same input.

doc_D3_Js
2016-11-24 10:28:33
Comments
Leave a Comment

Please login to continue.