Returns an accumulator function which incrementally computes a moving sample absolute Pearson product-moment correlation coefficient.
window size
mean value
mean value
accumulator function
var accumulator = incrmapcorr( 3, -2.0, 10.0 );
Returns an accumulator function which incrementally computes a moving sample absolute Pearson product-moment correlation coefficient.
window size
accumulator function
var accumulator = incrmapcorr( 3 );
var ar = accumulator();
// returns null
ar = accumulator( 2.0, 1.0 );
// returns 0.0
ar = accumulator( -5.0, 3.14 );
// returns ~1.0
ar = accumulator( 3.0, -1.0 );
// returns ~0.925
ar = accumulator( 5.0, -9.5 );
// returns ~0.863
ar = accumulator();
// returns ~0.863
If provided a value, the accumulator function returns an updated accumulated value. If not provided a value, the accumulator function returns the current accumulated value.
input value
input value
sample absolute correlation coefficient or null