Returns an accumulator function which incrementally computes a sum of squared absolute values.
accumulator function
var accumulator = incrsumabs2();
var v = accumulator();
// returns null
v = accumulator( 2.0 );
// returns 4.0
v = accumulator( -3.0 );
// returns 13.0
v = accumulator( -4.0 );
// returns 29.0
v = accumulator();
// returns 29.0
If provided a value, returns an updated sum of squared absolute values; otherwise, returns the current sum of squared absolute values.
Notes
NaN
or a value which, when used in computations, results inNaN
, the accumulated value isNaN
for all future invocations.value
sum of squared absolute values