This is excerpted from my work on emilio.js, a d3 plotting library, but useful enough to stand on its own.
- Generators are constructed with
new Path()
. - Takes two optional arguments,
xScale
andyScale
.- Methods for coordinate space translation.
- Works great with
d3.scale()
objects! xScale
andyScale
affect the x and y coordinate spaces, respectively.
- If only
xScale
is supplied, y values will be in thexScale
space.