Package mvpa :: Package featsel :: Module helpers :: Class BestDetector
[hide private]
[frames] | no frames]

Class BestDetector

source code


Determine whether the last value in a sequence is the best one given some criterion.
Instance Methods [hide private]
 
__init__(self, func=min, lastminimum=False)
Initialize with number of steps
source code
 
__call__(self, errors)
Returns True if the last value in errors is the best or False otherwise.
source code

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

Class Variables [hide private]
  bestindex = property(fget= lambda self: self.__bestindex)
Instance Variables [hide private]
  __bestindex
Stores the index of the last detected best value.
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, func=min, lastminimum=False)
(Constructor)

source code 
Initialize with number of steps
Parameters:
  • fun (functor) - Functor to select the best results. Defaults to min
  • lastminimum (bool) - Toggle whether the latest or the earliest minimum is used as optimal value to determine the stopping criterion.
Overrides: object.__init__