Reduce a list to a single value by iteratively applying a binary function
reduce() from the
reduce(.x, .f, ..., .init)
A list or atomic vector.
A 2-argument function. The function will be passed the accumulated value as the first argument and the "next" value as the second argument.
Additional arguments passed on to
If supplied, will be used as the first value to start the accumulation, rather than using
x[]. This is useful if you want to ensure that
reducereturns a correct value when
.xis empty. If missing, and
xis empty, will throw an error.