Scale normalised data
npm i scale-normalised
var Decimal = require('linear-arbitrary-precision')(require('floating-adapter'));
var scale = require('scale-normalised')(Decimal).scale;
scale([2, 4], .5); // => Decimal 3
scale([-3, 5], -.25); // => Decimal -5
See spec.
- linear-converter: flexible linear converter with built in conversions for common units.
- rescale: rescales a point given two scales.
- normalise: normalise data to [0, 1].
- rescale-util: rescale utilities.