Package rdkit :: Package ML :: Package Composite :: Module BayesComposite :: Class BayesComposite
[hide private]
[frames] | no frames]

Class BayesComposite

source code

         object --+    
                  |    
Composite.Composite --+
                      |
                     BayesComposite

a composite model using Bayesian statistics in the Decision Proxy


**Notes**

- typical usage:

   1) grow the composite with AddModel until happy with it

   2) call AverageErrors to calculate the average error values

   3) call SortModels to put things in order by either error or count

   4) call Train to update the Bayesian stats.

Instance Methods [hide private]
 
Train(self, data, verbose=0) source code
 
ClassifyExample(self, example, threshold=0, verbose=0, appendExample=0)
classifies the given example using the entire composite
source code
 
__init__(self)
x.__init__(...) initializes x; see help(type(x)) for signature
source code

Inherited from Composite.Composite: AddModel, AverageErrors, ClearModelExamples, CollectVotes, GetActivityQuantBounds, GetAllData, GetCount, GetDataTuple, GetDescriptorNames, GetError, GetInputOrder, GetModel, GetQuantBounds, GetVoteDetails, Grow, MakeHistogram, Pickle, QuantizeActivity, QuantizeExample, SetActivityQuantBounds, SetCount, SetDataTuple, SetDescriptorNames, SetError, SetInputOrder, SetModel, SetModelFilterData, SetQuantBounds, SortModels, __getitem__, __len__, __str__

Inherited from Composite.Composite (private): _RemapInput

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

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

ClassifyExample(self, example, threshold=0, verbose=0, appendExample=0)

source code 
classifies the given example using the entire composite

**Arguments**

 - example: the data to be classified

 - threshold:  if this is a number greater than zero, then a
    classification will only be returned if the confidence is
    above _threshold_.  Anything lower is returned as -1.

**Returns**

  a (result,confidence) tuple

Overrides: Composite.Composite.ClassifyExample

__init__(self)
(Constructor)

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

Overrides: object.__init__
(inherited documentation)