weka.classifiers.bayes.net.estimate
Class BMAEstimator

java.lang.Object
  extended byweka.classifiers.bayes.net.estimate.BayesNetEstimator
      extended byweka.classifiers.bayes.net.estimate.SimpleEstimator
          extended byweka.classifiers.bayes.net.estimate.BMAEstimator
All Implemented Interfaces:
OptionHandler, java.io.Serializable

public class BMAEstimator
extends SimpleEstimator

BMAEstimator estimates conditional probability tables of a Bayes network using Bayes Model Averaging (BMA).

Version:
$Revision: 1.4 $
Author:
Remco Bouckaert (rrb@xm.co.nz)
See Also:
Serialized Form

Constructor Summary
BMAEstimator()
           
 
Method Summary
 void estimateCPTs(BayesNet bayesNet)
          estimateCPTs estimates the conditional probability tables for the Bayes Net using the network structure.
 void initCPTs(BayesNet bayesNet)
          initCPTs reserves space for CPTs and set all counts to zero
 boolean isUseK2Prior()
           
 void setUseK2Prior(boolean bUseK2Prior)
          Sets the UseK2Prior.
 void updateClassifier(BayesNet bayesNet, Instance instance)
          Updates the classifier with the given instance.
 
Methods inherited from class weka.classifiers.bayes.net.estimate.SimpleEstimator
distributionForInstance
 
Methods inherited from class weka.classifiers.bayes.net.estimate.BayesNetEstimator
alphaTipText, getAlpha, getOptions, globalInfo, listOptions, setAlpha, setOptions
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BMAEstimator

public BMAEstimator()
Method Detail

estimateCPTs

public void estimateCPTs(BayesNet bayesNet)
                  throws java.lang.Exception
estimateCPTs estimates the conditional probability tables for the Bayes Net using the network structure.

Overrides:
estimateCPTs in class SimpleEstimator
Throws:
java.lang.Exception

updateClassifier

public void updateClassifier(BayesNet bayesNet,
                             Instance instance)
                      throws java.lang.Exception
Updates the classifier with the given instance.

Overrides:
updateClassifier in class SimpleEstimator
Parameters:
instance - the new training instance to include in the model
Throws:
java.lang.Exception - if the instance could not be incorporated in the model.

initCPTs

public void initCPTs(BayesNet bayesNet)
              throws java.lang.Exception
initCPTs reserves space for CPTs and set all counts to zero

Overrides:
initCPTs in class SimpleEstimator
Throws:
java.lang.Exception

isUseK2Prior

public boolean isUseK2Prior()
Returns:
boolean

setUseK2Prior

public void setUseK2Prior(boolean bUseK2Prior)
Sets the UseK2Prior.

Parameters:
bUseK2Prior - The bUseK2Prior to set