Package org.tribuo.classification.dtree
Class CARTClassificationOptions
java.lang.Object
org.tribuo.classification.dtree.CARTClassificationOptions
- All Implemented Interfaces:
com.oracle.labs.mlrg.olcut.config.Options
,ClassificationOptions<CARTClassificationTrainer>
public class CARTClassificationOptions
extends Object
implements ClassificationOptions<CARTClassificationTrainer>
Options for building a classification tree trainer.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
The impurity algorithm.static enum
Type of decision tree algorithm. -
Field Summary
Modifier and TypeFieldDescriptionImpurity measure to use.int
Maximum depth in the decision tree.float
Minimum child weight.float
Minimum impurity decrease.boolean
Prints the decision tree.boolean
Whether to choose split points for features at random.long
RNG seed.float
Fraction of features in split.Tree algorithm to use (options are CART).Fields inherited from interface com.oracle.labs.mlrg.olcut.config.Options
header
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionConstructs the trainer based on the provided arguments.
-
Field Details
-
cartMaxDepth
@Option(longName="cart-max-depth", usage="Maximum depth in the decision tree.") public int cartMaxDepthMaximum depth in the decision tree. -
cartMinChildWeight
@Option(longName="cart-min-child-weight", usage="Minimum child weight.") public float cartMinChildWeightMinimum child weight. -
cartMinImpurityDecrease
@Option(longName="cart-min-impurity-decrease", usage="Minimum impurity decrease.") public float cartMinImpurityDecreaseMinimum impurity decrease. -
cartSplitFraction
@Option(longName="cart-split-fraction", usage="Fraction of features in split.") public float cartSplitFractionFraction of features in split. -
cartRandomSplit
@Option(longName="cart-random-split", usage="Whether to choose split points for features at random.") public boolean cartRandomSplitWhether to choose split points for features at random. -
cartImpurity
@Option(longName="cart-impurity", usage="Impurity measure to use. Defaults to GINI.") public CARTClassificationOptions.ImpurityType cartImpurityImpurity measure to use. Defaults to GINI. -
cartPrintTree
@Option(longName="cart-print-tree", usage="Prints the decision tree.") public boolean cartPrintTreePrints the decision tree. -
cartTreeAlgorithm
@Option(longName="cart-tree-algorithm", usage="Tree algorithm to use (options are CART).") public CARTClassificationOptions.TreeType cartTreeAlgorithmTree algorithm to use (options are CART). -
cartSeed
@Option(longName="cart-seed", usage="RNG seed.") public long cartSeedRNG seed.
-
-
Constructor Details
-
CARTClassificationOptions
public CARTClassificationOptions()
-
-
Method Details
-
getOptionsDescription
- Specified by:
getOptionsDescription
in interfacecom.oracle.labs.mlrg.olcut.config.Options
-
getTrainer
Description copied from interface:ClassificationOptions
Constructs the trainer based on the provided arguments.- Specified by:
getTrainer
in interfaceClassificationOptions<CARTClassificationTrainer>
- Returns:
- The trainer.
-