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

Class Fcook

  object --+        
           |        
named._Named --+    
               |    
      _StatsBase --+
                   |
                  Fcook

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


See Also: Fwelford.

Instance Methods
 
__init__(self, xs=(), name='')
New Fcook accumulator.
 
__add__(self, other)
Sum of this and a scalar, an Fsum or an other instance.
 
__iadd__(self, other)
Add a scalar, an Fsum or an other instance to this instance.
 
__radd__(self, other)
Not implemented.
 
fadd(self, xs, sample=False)
Accumulate and return the current count.
 
fcopy(self, deep=False, name='')
Copy this instance, shallow or deep.
 
copy(self, deep=False, name='')
Copy this instance, shallow or deep.
 
fjb(self, xs=(), sample=True, excess=True)
Accumulate and compute the current Jarque-Bera normality.
 
fjb_(self, *xs, **excess_sample)
Accumulate and compute the current Jarque-Bera normality.
 
fkurtosis(self, xs=(), sample=False, excess=True)
Accumulate and return the current kurtosis.
 
fkurtosis_(self, *xs, **excess_sample)
Accumulate and return the current kurtosis.
 
fmean(self, xs=())
Accumulate and return the current mean.
 
fmedian(self, xs=())
Accumulate and return the current median.
 
fmedian_(self, *xs)
Accumulate and return the current median.
 
fskewness(self, xs=(), sample=False)
Accumulate and return the current skewness.
 
fskewness_(self, *xs, **sample)
Accumulate and return the current skewness.
 
fstdev(self, xs=(), sample=False)
Accumulate and return the current standard deviation.
 
fvariance(self, xs=(), sample=False)
Accumulate and return the current variance.

Inherited from _StatsBase: __len__, fadd_, fmean_, fstdev_, fvariance_

Inherited from named._Named: _DOT_, __imatmul__, __matmul__, __repr__, __rmatmul__, __str__, 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, name, named, named2, named3, named4

Inherited from object: __class__

Method Details

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

 

New Fcook accumulator.

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

See Also: Method Fcook.fadd.

__add__ (self, other)
(Addition operator)

 

Sum of this and a scalar, an Fsum or an other instance.

Arguments:
  • other - Fcook instance or a Scalar.
Returns:
The sum (Fcook).

See Also: Methods Fcook.__iadd__ and Fcook.fadd.

__iadd__ (self, other)

 

Add a scalar, an Fsum or an other instance to this instance.

Arguments:
  • other - Fcook instance or a Scalar.
Returns:
This instance, updated (Fcook).
Raises:
  • TypeError - Invalid other type.

See Also: Method Fcook.fadd.

fadd (self, xs, sample=False)

 

Accumulate and return the current count.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the full population value (bool).
Returns:
Current, running count (float).
Raises:
  • OverflowError - Partial 2sum overflow.
  • TypeError - Non-scalar xs value.
  • ValueError - Invalid or non-finite xs value.

Note: Scalar means an Fsum instance or scalar.

fcopy (self, deep=False, name='')

 

Copy this instance, shallow or deep.

Arguments:
  • deep - If True make a deep, otherwise a shallow copy (bool).
  • name - Optional, non-empty name (str).
Returns:
The copy (Fwelford).

copy (self, deep=False, name='')

 

Copy this instance, shallow or deep.

Arguments:
  • deep - If True make a deep, otherwise a shallow copy (bool).
  • name - Optional, non-empty name (str).
Returns:
The copy (Fwelford).
Overrides: named._Named.copy

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

 

Accumulate and compute the current Jarque-Bera normality.

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

See Also: Method Fcook.fadd.

fjb_ (self, *xs, **excess_sample)

 

Accumulate and compute the current Jarque-Bera normality.

See Also: Method Fcook.fjb.

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

 

Accumulate and return the current kurtosis.

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

fkurtosis_ (self, *xs, **excess_sample)

 

Accumulate and return the current kurtosis.

See Also: Method Fcook.fkurtosis.

fmean (self, xs=())

 

Accumulate and return the current mean.

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

See Also: Method Fcook.fadd.

fmedian (self, xs=())

 

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=(), sample=False)

 

Accumulate and return the current skewness.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the full population value (bool).
Returns:
Current, running 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.

fstdev (self, xs=(), sample=False)

 

Accumulate and return the current standard deviation.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the full population value (bool).
Returns:
Current, running standard deviation (float).

See Also: Method Fcook.fadd.

fvariance (self, xs=(), sample=False)

 

Accumulate and return the current variance.

Arguments:
  • xs - Iterable with additional values (Scalars).
  • sample - Return the sample instead of the full population value (bool).
Returns:
Current, running variance (float).

See Also: Method Fcook.fadd.