accumulate

accumulate(fs)
Fieldset.accumulate()

Computes the sum of all the values for each field in fs.

Parameters

fs (Fieldset) – input fieldset

Return type

number or list or None

If there is only one field in fs it returns a number, otherwise a list is returned. Only non-missing values are considered in the calculation. For fields with no valid values NaN is returned.