severo
September 13, 2020, 3:14pm
1
I made the exercise to use d3.piecewise, d3.range, d3.interpolateObject, etc. to sample a trajectory (x/y points in time): https://observablehq.com/@severo/trajectory-sampling-with-d3-js
But the interpolation between the points is linear. I wonder if D3.js provides the tools to do other interpolations, such as the ones d3-shape provides for curves
D3 supports basis interpolation:
Interpolate numbers, colors, strings, arrays, objects, whatever! - d3/d3-interpolate
There’s been discussion about other sorts of splines (monotonic in particular). We might add more.
1 Like
severo
September 13, 2020, 3:20pm
3
OK ! I will add the spline interpolation to the notebook, thanks
severo
February 2, 2021, 6:16pm
5
severo
February 2, 2021, 6:16pm
6