org.apache.spark.mllib.tree.configuration
Class BoostingStrategy
Object
org.apache.spark.mllib.tree.configuration.BoostingStrategy
- All Implemented Interfaces:
- java.io.Serializable, scala.Equals, scala.Product
public class BoostingStrategy
- extends Object
- implements scala.Serializable, scala.Product
:: Experimental ::
Configuration options for GradientBoostedTrees
.
param: treeStrategy Parameters for the tree algorithm. We support regression and binary
classification for boosting. Impurity setting will be ignored.
param: loss Loss function used for minimization during gradient boosting.
param: numIterations Number of iterations of boosting. In other words, the number of
weak hypotheses used in the final model.
param: learningRate Learning rate for shrinking the contribution of each estimator. The
learning rate should be between in the interval (0, 1]
param: validationTol Useful when runWithValidation is used. If the error rate on the
validation input between two iterations is less than the validationTol
then stop. Ignored when run
is used.
- See Also:
- Serialized Form
Methods inherited from class Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface scala.Product |
productArity, productElement, productIterator, productPrefix |
Methods inherited from interface scala.Equals |
canEqual, equals |
BoostingStrategy
public BoostingStrategy(Strategy treeStrategy,
Loss loss,
int numIterations,
double learningRate,
double validationTol)
defaultParams
public static BoostingStrategy defaultParams(String algo)
defaultParams
public static BoostingStrategy defaultParams(scala.Enumeration.Value algo)
treeStrategy
public Strategy treeStrategy()
setTreeStrategy
public void setTreeStrategy(Strategy x$1)
loss
public Loss loss()
setLoss
public void setLoss(Loss x$1)
numIterations
public int numIterations()
setNumIterations
public void setNumIterations(int x$1)
learningRate
public double learningRate()
setLearningRate
public void setLearningRate(double x$1)
validationTol
public double validationTol()
setValidationTol
public void setValidationTol(double x$1)
getTreeStrategy
public Strategy getTreeStrategy()
getLoss
public Loss getLoss()
getNumIterations
public int getNumIterations()
getLearningRate
public double getLearningRate()
getValidationTol
public double getValidationTol()