robust-abs
Math.abs for non-overlapping increasing sequences
install
npm install robust-abs
use
You'll want to have a non-overlapping increasing sequence that came from a packages in the robust family of packages.
For this example sake we'll simulate that here by using robust-split
which will convert a JavaScript number into a non-overlapping increasing sequence. We'll also be using robust-estimate-float
to provide more human readable results.
var split = ;var abs = ;var estimate = ; var seq = ;console; // [ -1.8626451769865326e-10, -0.049999999813735485 ] var res = ;console; // [ 1.8626451769865326e-10, 0.049999999813735485 ] console // 0.05