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

Class Fcook

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

Cook's RunningStats computing the running mean, median and (sample) kurtosis, skewness, variance, standard deviation and Jarque-Bera normality.


See Also: Fwelford and Higher-order statistics.

Instance Methods
 
__init__(self, xs=None, name='')
New Fcook stats accumulator.
 
__iadd__(self, other)
Add other to this Fcook instance.
 
fadd(self, xs, sample=False)
Accumulate and return the current count.
 
fjb(self, xs=None, sample=True, excess=True)
Accumulate and compute the current Jarque-Bera normality.
 
fjb_(self, *xs, **sample_excess)
Accumulate and compute the current Jarque-Bera normality.
 
fkurtosis(self, xs=None, sample=False, excess=True)
Accumulate and return the current kurtosis.
 
fkurtosis_(self, *xs, **sample_excess)
Accumulate and return the current kurtosis.
 
fmedian(self, xs=None)
Accumulate and return the current median.
 
fmedian_(self, *xs)
Accumulate and return the current median.
 
fskewness(self, xs=None, sample=False)
Accumulate and return the current skewness.
 
fskewness_(self, *xs, **sample)
Accumulate and return the current skewness.
 
toFwelford(self, name='')
Return an Fwelford equivalent.

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, methodname, 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, sizeof

Inherited from object: __class__

Method Details

__init__ (self, xs=None, name='')
(Constructor)

 

New Fcook stats accumulator.

Arguments:
  • xs - Iterable with initial values (Scalars).
  • name - Optional name (str).
Overrides: object.__init__

See Also: Method Fcook.fadd.

__iadd__ (self, other)

 

Add other to this Fcook instance.

Arguments:
  • other - An Fcook instance or Scalars, meaning one or more scalar or Fsum instances.
Returns:
This instance, updated (Fcook).
Raises:
  • TypeError - Invalid other type.
  • ValueError - Invalid other.

See Also: Method Fcook.fadd.

fadd (self, xs, sample=False)

 

Accumulate and return the current count.

Arguments:
  • xs - Iterable with additional values (Scalars, meaning scalar or Fsum instances).
  • sample - Return the sample instead of the entire population count (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

See Also: online_kurtosis.

fjb (self, xs=None, sample=True, excess=True)

 

Accumulate and compute the current Jarque-Bera normality.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample normality (bool), default.
  • excess - Return the excess kurtosis (bool), default.
Returns:
Current, running (sample) Jarque-Bera normality (float).

See Also: Method Fcook.fadd.

fjb_ (self, *xs, **sample_excess)

 

Accumulate and compute the current Jarque-Bera normality.

See Also: Method Fcook.fjb.

fkurtosis (self, xs=None, sample=False, excess=True)

 

Accumulate and return the current kurtosis.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the entire population kurtosis (bool).
  • excess - Return the excess kurtosis (bool), default.
Returns:
Current, running (sample) kurtosis or excess kurtosis (float).
See Also:
Kurtosis Formula and Mantalos., Method Fcook.fadd.

fkurtosis_ (self, *xs, **sample_excess)

 

Accumulate and return the current kurtosis.

See Also: Method Fcook.fkurtosis.

fmedian (self, xs=None)

 

Accumulate and return the current median.

Arguments:
  • xs - Iterable with additional values (Scalars).
Returns:
Current, running median (float).

fmedian_ (self, *xs)

 

Accumulate and return the current median.

See Also: Method Fcook.fmedian.

fskewness (self, xs=None, sample=False)

 

Accumulate and return the current skewness.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the entire population skewness (bool).
Returns:
Current, running (sample) skewness (float).
See Also:
Skewness Formula and Mantalos., Method Fcook.fadd.

fskewness_ (self, *xs, **sample)

 

Accumulate and return the current skewness.

See Also: Method Fcook.fskewness.