We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Estimate new values between existing ones.
Similar: interleave, intermix, interpolate, intersperse.
function interpolate(x, fc) // x: an iterable // fc: combine function (a, b)
const xiterable = require('extra-iterable'); var x = [1, 2, 3]; [...xiterable.interpolate(x, (a, b) => (a + b)/2)]; // → [1, 1.5, 2, 2.5, 3]