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