Oracle Data Mining Java API Reference
10g Release 1 (10.1)

B12276-01

oracle.dmt.odm.settings.algorithm
Class AdaptiveBayesNetworkSettings

java.lang.Object
  |
  +--oracle.dmt.odm.MiningObject
        |
        +--oracle.dmt.odm.settings.algorithm.MiningAlgorithmSettings
              |
              +--oracle.dmt.odm.settings.algorithm.AdaptiveBayesNetworkSettings
All Implemented Interfaces:
java.io.Serializable

public class AdaptiveBayesNetworkSettings
extends MiningAlgorithmSettings

An instance of AdaptiveBayesNetworkSettings is used to specify settings for the Adaptive Bayes Network algorithm. The settings are intended to allow the user control over build performance. The build process includes a step that finds an array of seed features. A seed feature consists of a training attribute that is statistically correlated with the target. In a training table with many attributes, many seed features may be found. The statistical procedure ranks the seed features with respect to their statistical correlation. The first step consists of constructing a Naive Bayes Model of size specified by numberOfPredictorsInNBModel parameter consisting of the top ranked attributes. Subsequent steps extend each seed feature one at a time in rank order. The maximum number of seed features extended is specified by maximum predictors. Each step must yield a model of smaller description length or it is rejected. The initial baseline is the global target distribution or prior. Each time a seed feature is extended, it involves a scan of the table.

To control the length of time it takes for the build, there are six user parameters:

Since:
9.2.0
See Also:
Serialized Form

Constructor Summary
AdaptiveBayesNetworkSettings()
          Creates a AdaptiveBayesNetworkSettings default settings object.
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth)
          Creates an AdaptiveBayesNetworkSettings.
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumPredictors)
          Creates an AdaptiveBayesNetworkSettings.
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumPredictors, ABNModelBuildType modelBuildType)
          Creates an AdaptiveBayesNetworkSettings
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumNumberOfNetworkFeatures, int maximumConsecutivePrunedNetworkFeatures)
          Deprecated. As of ODM 9.2.0.4
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumPredictors, int maximumBuildTime, ABNModelBuildType modelBuildType)
          Creates an AdaptiveBayesNetworkSettings
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumNumberOfNetworkFeatures, int maximumConsecutivePrunedNetworkFeatures, int maximumBuildTime)
          Deprecated. As of ODM 9.2.0.4
AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth, int maximumConsecutivePrunedNetworkFeatures, int maximumPredictors, int numberOfPredictorsInNBModel, int maximumBuildTime, ABNModelBuildType modelBuildType)
          Creates an AdaptiveBayesNetworkSettings

 

Method Summary
 int getMaximumBuildTime()
          Returns the maximum build time.
 int getMaximumConsecutivePrunedNetworkFeatures()
          Returns the maximum number of consecutive pruned features before halting the stepwise selection process.
 int getMaximumNetworkFeatureDepth()
          Returns the maximum depth of any NetworkFeature.
 int getMaximumNumberOfNetworkFeatures()
          Deprecated. As of ODM 9.2.0.4, this method is replaced by getMaxPredictors and getNaiveBayesNumPredictors.
 int getMaximumPredictors()
          Returns maximum number of predictors chosen during predictor selection phase, any data.
 ABNModelBuildType getModelBuildType()
          Returns the model build type.
 int getNaiveBayesNumberPredictors()
          Returns the number of predictors in the NB model.
 void setMaximumBuildTime(int maximumBuildTime)
          Sets the maximum build time.
 void setMaximumConsecutivePrunedNetworkFeatures(int maximumConsecutivePrunedNetworkFeatures)
          Sets the maximum number of consecutive pruned features before halting the stepwise selection process.
 void setMaximumNetworkFeatureDepth(int maximumNetworkFeatureDepth)
          Sets the maximum depth of any NetworkFeature.
 void setMaximumNumberOfNetworkFeatures(int maximumNumberOfNetworkFeatures)
          Deprecated. As of ODM 9.2.0.4, this method is replaced by setMaxPredictors and setNaiveBayesNumPredictors.
 void setMaximumPredictors(int maximumPredictors)
          Sets maximum number of predictors chosen during predictor selection phase.
 void setModelBuildType(ABNModelBuildType modelBuildType)
          Sets model build type.
 void setNaiveBayesNumberPredictors(int numberOfPredictorsInNBModel)
          Sets the number of predictors in the Naive Bayes model.
 void validate()
          Validates all settings.

 

Methods inherited from class oracle.dmt.odm.settings.algorithm.MiningAlgorithmSettings
getMiningAlgorithm, getMiningAlgorithmName

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings()
Creates a AdaptiveBayesNetworkSettings default settings object.
Since:
9.2.0.4

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth)
                             throws InvalidArgumentException
Creates an AdaptiveBayesNetworkSettings.
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
Throws:
InvalidArgumentException - when the maximumNetworkFeatureDepth < 0.
Since:
9.2.0.4

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumPredictors)
                             throws InvalidArgumentException
Creates an AdaptiveBayesNetworkSettings.
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
maximumPredictors - maximum number of predictors chosen during predictor selection phase.
Throws:
InvalidArgumentException -
Since:
9.2.0.4

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumPredictors,
ABNModelBuildType modelBuildType)
                             throws InvalidArgumentException
Creates an AdaptiveBayesNetworkSettings
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
maximumPredictors - maximum number of predictors chosen during predictor selection phase.
modelBuildType - model build type.
Throws:
InvalidArgumentException -
Since:
9.2.0.4

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumPredictors,
                                    int maximumBuildTime,
ABNModelBuildType modelBuildType)
                             throws InvalidArgumentException
Creates an AdaptiveBayesNetworkSettings
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
maximumPredictors - maximum number of predictors chosen during predictor selection phase.
maximumBuildTime - maximum build time. Set to 0 for no time limit.
modelBuildType - model build type.
Throws:
InvalidArgumentException -
Since:
9.2.0.4

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumNumberOfNetworkFeatures,
                                    int maximumConsecutivePrunedNetworkFeatures)
                             throws InvalidArgumentException
Deprecated. As of ODM 9.2.0.4
Creates an AdaptiveBayesNetworkSettings.
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300.
maximumNumberOfNetworkFeatures - maximum number of seed NetworkFeatures trees that are candidates for extension and size of baseline Naive Bayes model. Setting closer to 1 builds the model faster. Can be set to the number of attributes.
maximumConsecutivePrunedNetworkFeatures - maximum number of consecutive pruned features before halting the stepwise selection process. Negative value specifies that only a single feature and the baseline Naive Bayes model will be constructed. Setting closer to 1 builds the model faster. Set to -1 when the number of rows > 300,000 and the number of attributes > 40.
Throws:
InvalidArgumentException -

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumNumberOfNetworkFeatures,
                                    int maximumConsecutivePrunedNetworkFeatures,
                                    int maximumBuildTime)
                             throws InvalidArgumentException
Deprecated. As of ODM 9.2.0.4
Creates an AdaptiveBayesNetworkSettings
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300.
maximumNumberOfNetworkFeatures - maximum number of seed NetworkFeatures trees that are candidates for extension and size of baseline Naive Bayes model. Setting closer to 1 builds the model faster. Can be set to the number of attributes.
maximumConsecutivePrunedNetworkFeatures - maximum number of consecutive pruned features before halting the stepwise selection process. Negative value specifies that only a single feature and the baseline Naive Bayes model will be constructed. Setting closer to 1 builds the model faster. Negative values are fastest. Set to -1 when the number of rows > 300,000 and the number of attributes > 40.
maximumBuildTime - maximum build time
Throws:
InvalidArgumentException -

AdaptiveBayesNetworkSettings

public AdaptiveBayesNetworkSettings(int maximumNetworkFeatureDepth,
                                    int maximumConsecutivePrunedNetworkFeatures,
                                    int maximumPredictors,
                                    int numberOfPredictorsInNBModel,
                                    int maximumBuildTime,
ABNModelBuildType modelBuildType)
                             throws InvalidArgumentException
Creates an AdaptiveBayesNetworkSettings
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
maximumConsecutivePrunedNetworkFeatures - maximum number of consecutive pruned features before halting the stepwise selection process. This setting is ignored if the model type is not MultiFeatureBuild.
maximumPredictors - maximum number of predictors chosen during predictor selection phase.
numberOfPredictorsInNBModel - number of predictors in the NB model. This setting is ignored if the model type is neither NaiveBayesBuild nor MultiFeatureBuild.
maximumBuildTime - maximum build time. Set to 0 for no time limit.
modelBuildType - model build type.
Throws:
InvalidArgumentException -
Since:
9.2.0.4
Method Detail

getMaximumNetworkFeatureDepth

public int getMaximumNetworkFeatureDepth()
Returns the maximum depth of any NetworkFeature.
Returns:
maximum depth of any NetworkFeature

getMaximumNumberOfNetworkFeatures

public int getMaximumNumberOfNetworkFeatures()
Deprecated. As of ODM 9.2.0.4, this method is replaced by getMaxPredictors and getNaiveBayesNumPredictors.
Returns the maximum number of seed NetworkFeatures trees that are candidates for extension and size of baseline Naive Bayes model.
Returns:
maximum number of Network Feature

getMaximumPredictors

public int getMaximumPredictors()
Returns maximum number of predictors chosen during predictor selection phase, any data. This parameter does predictor selection for performance reason. The top k predictors are selected where k = MaxPredictors.
Returns:
maximum number of predictors chosen during predictor selection phase, any data
Since:
9.2.0.4

getNaiveBayesNumberPredictors

public int getNaiveBayesNumberPredictors()
Returns the number of predictors in the NB model. The actual number of predictors will be the minimum of the parameter value and the number of active predictors in the model. If the value is less than the number of active predictors in the model, the predictors are chosen in accordance with their MDL rank.
Returns:
number of predictors in the Naive Bayes model
Since:
9.2.0.4

getMaximumConsecutivePrunedNetworkFeatures

public int getMaximumConsecutivePrunedNetworkFeatures()
Returns the maximum number of consecutive pruned features before halting the stepwise selection process.
Returns:
maximum number of consecutive pruned Network Feature

getMaximumBuildTime

public int getMaximumBuildTime()
Returns the maximum build time.
Returns:
maximum build time

getModelBuildType

public ABNModelBuildType getModelBuildType()
Returns the model build type.
Returns:
Model build type
Since:
9.2.0.4

setMaximumNetworkFeatureDepth

public void setMaximumNetworkFeatureDepth(int maximumNetworkFeatureDepth)
                                   throws InvalidArgumentException
Sets the maximum depth of any NetworkFeature.
Parameters:
maximumNetworkFeatureDepth - maximum depth of any NetworkFeature. Setting closer to 1 builds the model faster. Set to 1 if the number of attributes is greater than the number of rows or the number of rows is < 300. Set to 0 for unrestricted depth.
Throws:
InvalidArgumentException - when the maximumNetworkFeatureDepth < 0.

setMaximumNumberOfNetworkFeatures

public void setMaximumNumberOfNetworkFeatures(int maximumNumberOfNetworkFeatures)
                                       throws InvalidArgumentException
Deprecated. As of ODM 9.2.0.4, this method is replaced by setMaxPredictors and setNaiveBayesNumPredictors.
Sets the maximum number of seed NetworkFeatures trees that are candidates for extension and size of baseline Naive Bayes model.
Parameters:
maximumNumberOfNetworkFeatures - maximum number of seed NetworkFeatures trees that are candidates for extension and size of baseline Naive Bayes model. Setting closer to 1 builds the model faster. Can be set to the number of attributes.
Throws:
InvalidArgumentException - is thrown when the maximumNumberOfNetworkFeatures < 0.
InvalidArgumentException

setMaximumPredictors

public void setMaximumPredictors(int maximumPredictors)
                          throws InvalidArgumentException
Sets maximum number of predictors chosen during predictor selection phase.
Parameters:
maximumPredictors - maximum number of predictors chosen during predictor selection phase.
Throws:
InvalidArgumentException - when the maximumPredictors < 1.
Since:
9.2.0.4

setNaiveBayesNumberPredictors

public void setNaiveBayesNumberPredictors(int numberOfPredictorsInNBModel)
                                   throws InvalidArgumentException
Sets the number of predictors in the Naive Bayes model.
Parameters:
numberOfPredictorsInNBModel - number of predictors in the Naive Bayes model. This setting is ignored if the model type is neither NaiveBayesBuild nor MultiFeatureBuild.
Throws:
InvalidArgumentException - when model build type is NaiveBayesBuild or MultiFeatureBuild and numberOfPredictorsInNBModel < 1.
Since:
9.2.0.4

setMaximumConsecutivePrunedNetworkFeatures

public void setMaximumConsecutivePrunedNetworkFeatures(int maximumConsecutivePrunedNetworkFeatures)
                                                throws InvalidArgumentException
Sets the maximum number of consecutive pruned features before halting the stepwise selection process.
Parameters:
maximumConsecutivePrunedNetworkFeatures - maximum number of consecutive pruned features before halting the stepwise selection process. Setting closer to 1 builds the model faster. This setting is ignored if the model type is not MultiFeatureBuild.
Throws:
InvalidArgumentException - when model build type is MultiFeatureBuild and maximumConsecutivePrunedNetworkFeatures < 1.

setMaximumBuildTime

public void setMaximumBuildTime(int maximumBuildTime)
                         throws InvalidArgumentException
Sets the maximum build time.
Parameters:
maximumBuildTime - maximum build time
Throws:
InvalidArgumentException - when the maximumBuildTime < 0

setModelBuildType

public void setModelBuildType(ABNModelBuildType modelBuildType)
Sets model build type.
Parameters:
modelBuildType -
Since:
9.2.0.4
See Also:
ABNModelBuildType

validate

public void validate()
              throws MiningObjectException
Validates all settings.
Overrides:
validate in class MiningAlgorithmSettings
Throws:
MiningObjectException -
  • when the maximumNetworkFeatureDepth < 0,
  • when the maximumPredictors < 1,
  • when model build type is NaiveBayesBuild or MultiFeatureBuild and numberOfPredictorsInNBModel < 1,
  • when model build type is MultiFeatureBuild and maximumConsecutivePrunedNetworkFeatures < 1, or
  • when the maximumBuildTime < 0.

Copyright © 2003 Oracle Corporation. All Rights Reserved.