Package pygeodesy :: Module fstats :: Class Fwelford |
[frames] | no frames]

# Class Fwelford

      object --+
               |
    named._Named --+
                   |
        _FstatsNamed --+
                       |
             _FstatsBase --+
                           |
                          Fwelford

Welford's accumulator computing the running mean, (sample) variance and standard deviation.

See Also: Cook and Fcook.

Instance Methods
__init__(self, xs=None, name='') New Fwelford stats accumulator. |
__iadd__(self, other) Add `other` to this Fwelford instance. |
fadd(self, xs, sample=False) Accumulate and return the current count. |
Inherited from `_FstatsBase`: `fadd_`, `fmean`, `fmean_`, `fstdev`, `fstdev_`, `fvariance`, `fvariance_` Inherited from `_FstatsNamed`: `__add__`, `__float__`, `__int__`, `__len__`, `__neg__`, `__radd__`, `__str__`, `copy`, `fcopy` Inherited from `named._Named`: `__imatmul__`, `__matmul__`, `__repr__`, `__rmatmul__`, `attrs`, `classof`, `dup`, `rename`, `toRepr`, `toStr`, `toStr2` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Properties
Inherited from `named._Named`: `classname`, `classnaming`, `iteration`, `name`, `named`, `named2`, `named3`, `named4` Inherited from `object`: `__class__`

Method Details

### __init__ (self, xs=None, name='') (Constructor) |
New Fwelford stats accumulator. Arguments: `xs` - Iterable with initial values (`Scalar`s). `name` - Optional name (`str`). Overrides: object.__init__ See Also: Method Fwelford.fadd.

### __iadd__ (self, other) |
Add `other` to this Fwelford instance. Arguments: `other` - An Fwelford or Fcook instance or `Scalar`s, meaning one or more `scalar` or Fsum instances. Returns: This instance, updated (Fwelford). Raises: `TypeError` - Invalid `other` type. `ValueError` - Invalid `other`. See Also: Method Fwelford.fadd and Parallel algorithm.

### fadd (self, xs, sample=False) |
Accumulate and return the current count. Arguments: `xs` - Iterable with additional values (`Scalar`s, meaning `scalar` or Fsum instances). `sample` - Return the sample instead of the entire population value (`bool`). Returns: Current, running (sample) count (`int`). Raises: `OverflowError` - Partial `2sum` overflow. `TypeError` - Non-scalar `xs` value. `ValueError` - Invalid or non-finite `xs` value. Overrides: _FstatsBase.fadd