d3 / d3-interpolate

Interpolate numbers, colors, strings, arrays, objects, whatever!
https://d3js.org/d3-interpolate
ISC License
493 stars 70 forks source link

interpolateNumberArrayRound ? #78

Closed Fil closed 4 years ago

Fil commented 4 years ago

I just realized that in #77, for integer arrays, the implicit rounding is floor when we would want round, for symmetry. I'm not sure where to put that change: in array type detection, and/or in an explicit interpolateNumberArrayRound function.

(Sorry for l'esprit d'escalier)

mbostock commented 4 years ago

Feels too niche to me.

Fil commented 4 years ago

I would have liked the symmetry, but it's not that easy to code.