Package parsimony :: Module estimators :: Class BaseEstimator
[hide private]
[frames] | no frames]

Class BaseEstimator

source code

object --+
         |
        BaseEstimator
Known Subclasses:

Base class for estimators.

Parameters
----------
algorithm : BaseAlgorithm. The algorithm that will be used.

Nested Classes [hide private]
  __metaclass__
Metaclass for defining Abstract Base Classes (ABCs).
Instance Methods [hide private]
 
__init__(self, algorithm)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
set_params(self, **kwargs)
Set the given input parameters in the estimator.
source code
 
get_params(self)
Return a dictionary containing the estimator's own input parameters.
source code
 
fit(self, X)
Fit the estimator to the data.
source code
 
predict(self, X)
Perform prediction using the fitted parameters.
source code
 
parameters(self)
Returns the estimator's fitted parameters, e.g.
source code
 
score(self, X, y) source code
 
get_info(self)
If an InformationAlgorithm, returns the information dictionary.
source code

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

Class Variables [hide private]
  __abstractmethods__ = frozenset(['get_params', 'predict', 'sco...
  _abc_cache = <_weakrefset.WeakSet object at 0x3378390>
  _abc_negative_cache = <_weakrefset.WeakSet object at 0x3378410>
  _abc_negative_cache_version = 14
  _abc_registry = <_weakrefset.WeakSet object at 0x33782d0>
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, algorithm)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

get_params(self)

source code 

Return a dictionary containing the estimator's own input parameters.

Decorators:
  • @abc.abstractmethod

predict(self, X)

source code 

Perform prediction using the fitted parameters.

Decorators:
  • @abc.abstractmethod

parameters(self)

source code 

Returns the estimator's fitted parameters, e.g. the regression coefficients.

What is returned depends on the estimator. See the estimator's documentation.

score(self, X, y)

source code 
Decorators:
  • @abc.abstractmethod

Class Variable Details [hide private]

__abstractmethods__

Value:
frozenset(['get_params', 'predict', 'score'])