repl.txt (739B)
1 2 {{alias}}() 3 Returns an accumulator function which incrementally computes an arithmetic 4 mean of absolute values. 5 6 If provided a value, the accumulator function returns an updated mean. If 7 not provided a value, the accumulator function returns the current mean. 8 9 If provided `NaN` or a value which, when used in computations, results in 10 `NaN`, the accumulated value is `NaN` for all future invocations. 11 12 Returns 13 ------- 14 acc: Function 15 Accumulator function. 16 17 Examples 18 -------- 19 > var accumulator = {{alias}}(); 20 > var mu = accumulator() 21 null 22 > mu = accumulator( 2.0 ) 23 2.0 24 > mu = accumulator( -5.0 ) 25 3.5 26 > mu = accumulator() 27 3.5 28 29 See Also 30 -------- 31