-
Notifications
You must be signed in to change notification settings - Fork 0
Hull Geom
jasondavies edited this page Mar 24, 2013
·
3 revisions
Wiki ▸ API Reference ▸ Geometry ▸ Hull Geom
# d3.geom.hull([vertices])
If vertices is specified, returns their convex hull, using the default x- and y-coordinate accessors. The convex hull is represented by an array containing a subset of the input vertices, arranged in clockwise order.
If vertices is not specified, creates a new hull layout with the default settings.
# hull.x([x])
If x is specified, sets the x-coordinate accessor. If x is not specified, returns the current x-coordinate accessor, which defaults to:
function(d) { return d[0]; }# hull.y([y])
If y is specified, sets the y-coordinate accessor. If y is not specified, returns the current y-coordinate accessor, which defaults to:
function(d) { return d[1]; }