Public
Edited
Dec 14, 2022
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
interpolateBasis = function(values) {
const valuePolator = d3.interpolateBasis(values);
return sampler.map((t) => valuePolator(t));
};
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
interpolateCardinal = function(values) {
const valuePolator = d3.interpolateCardinal(values);
return sampler.map((t) => valuePolator(t));
};
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
interpolateCatmullRom = function(values) {
const valuePolator = d3.interpolateCatmullRom(values);
return sampler.map((t) => valuePolator(t));
};
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
interpolateMonotoneX = function(values) {
const valuePolator = d3.interpolateMonotoneX(values);
return sampler.map((t) => valuePolator(t));
};
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
interpolateLinear = function(values) {
const valuePolator = d3.interpolateFromCurve(values, d3.curveLinear);
return sampler.map((t) => valuePolator(t));
};
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
sampler = d3.range(0, 1, 1 / samples);
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more