Package mdp :: Package nodes :: Class _OneDimensionalHitParade
[hide private]
[frames] | no frames]

Class _OneDimensionalHitParade


Class to produce hit-parades (i.e., a list of the largest and smallest values) out of a one-dimensional time-series.
Instance Methods [hide private]
 
__init__(self, n, d, real_dtype='d', integer_dtype='l')
Input arguments: n -- Number of maxima and minima to remember d -- Minimum gap between two hits
 
get_maxima(self)
Return the tuple (maxima, time-indices). Maxima are sorted in descending order.
 
get_minima(self)
Return the tuple (minima, time-indices). Minima are sorted in ascending order.
 
update(self, inp)
Input arguments: inp -- tuple (time-series, time-indices)

Inherited from unreachable.newobject: __long__, __native__, __nonzero__, __unicode__, next

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, n, d, real_dtype='d', integer_dtype='l')
(Constructor)

 

Input arguments: n -- Number of maxima and minima to remember d -- Minimum gap between two hits

real_dtype -- dtype of sequence items integer_dtype -- dtype of sequence indices Note: be careful with dtypes!

Overrides: object.__init__

get_maxima(self)

 
Return the tuple (maxima, time-indices). Maxima are sorted in descending order.

get_minima(self)

 
Return the tuple (minima, time-indices). Minima are sorted in ascending order.

update(self, inp)

 
Input arguments: inp -- tuple (time-series, time-indices)