public class RandomForestClassifier extends ProbabilisticClassifier<Vector,RandomForestClassifier,RandomForestClassificationModel> implements RandomForestClassifierParams, DefaultParamsWritable
| Constructor and Description |
|---|
RandomForestClassifier() |
RandomForestClassifier(String uid) |
| Modifier and Type | Method and Description |
|---|---|
RandomForestClassifier |
copy(ParamMap extra)
Creates a copy of this instance with the same UID and some extra params.
|
static RandomForestClassifier |
load(String path) |
static MLReader<T> |
read() |
RandomForestClassifier |
setCacheNodeIds(boolean value) |
RandomForestClassifier |
setCheckpointInterval(int value)
Specifies how often to checkpoint the cached node IDs.
|
RandomForestClassifier |
setFeatureSubsetStrategy(String value) |
RandomForestClassifier |
setImpurity(String value) |
RandomForestClassifier |
setMaxBins(int value) |
RandomForestClassifier |
setMaxDepth(int value) |
RandomForestClassifier |
setMaxMemoryInMB(int value) |
RandomForestClassifier |
setMinInfoGain(double value) |
RandomForestClassifier |
setMinInstancesPerNode(int value) |
RandomForestClassifier |
setNumTrees(int value) |
RandomForestClassifier |
setSeed(long value) |
RandomForestClassifier |
setSubsamplingRate(double value) |
static String[] |
supportedFeatureSubsetStrategies()
Accessor for supported featureSubsetStrategy settings: auto, all, onethird, sqrt, log2
|
static String[] |
supportedImpurities()
Accessor for supported impurity settings: entropy, gini
|
String |
uid()
An immutable unique ID for the object and its derivatives.
|
setProbabilityCol, setThresholdssetRawPredictionColfit, setFeaturesCol, setLabelCol, setPredictionCol, transformSchemaequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetNumTrees, numTreesfeatureSubsetStrategy, getFeatureSubsetStrategy, getOldStrategy, getSubsamplingRate, subsamplingRatecacheNodeIds, getCacheNodeIds, getMaxBins, getMaxDepth, getMaxMemoryInMB, getMinInfoGain, getMinInstancesPerNode, getOldStrategy, maxBins, maxDepth, maxMemoryInMB, minInfoGain, minInstancesPerNodevalidateAndTransformSchemagetLabelCol, labelColfeaturesCol, getFeaturesColgetPredictionCol, predictionColclear, copyValues, defaultCopy, defaultParamMap, explainParam, explainParams, extractParamMap, extractParamMap, get, getDefault, getOrDefault, getParam, hasDefault, hasParam, isDefined, isSet, paramMap, params, set, set, set, setDefault, setDefault, shouldOwntoStringcheckpointInterval, getCheckpointIntervalgetImpurity, getOldImpurity, impuritywritesavevalidateAndTransformSchemagetRawPredictionCol, rawPredictionColgetProbabilityCol, probabilityColgetThresholds, thresholdsinitializeLogging, initializeLogIfNecessary, initializeLogIfNecessary, isTraceEnabled, log_, log, logDebug, logDebug, logError, logError, logInfo, logInfo, logName, logTrace, logTrace, logWarning, logWarningpublic RandomForestClassifier(String uid)
public RandomForestClassifier()
public static final String[] supportedImpurities()
public static final String[] supportedFeatureSubsetStrategies()
public static RandomForestClassifier load(String path)
public static MLReader<T> read()
public String uid()
Identifiableuid in interface Identifiablepublic RandomForestClassifier setMaxDepth(int value)
setMaxDepth in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setMaxBins(int value)
setMaxBins in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setMinInstancesPerNode(int value)
setMinInstancesPerNode in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setMinInfoGain(double value)
setMinInfoGain in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setMaxMemoryInMB(int value)
setMaxMemoryInMB in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setCacheNodeIds(boolean value)
setCacheNodeIds in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setCheckpointInterval(int value)
SparkContext.
Must be at least 1.
(default = 10)setCheckpointInterval in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setImpurity(String value)
setImpurity in interface TreeClassifierParamsvalue - (undocumented)public RandomForestClassifier setSubsamplingRate(double value)
setSubsamplingRate in interface TreeEnsembleParamsvalue - (undocumented)public RandomForestClassifier setSeed(long value)
setSeed in interface DecisionTreeParamsvalue - (undocumented)public RandomForestClassifier setNumTrees(int value)
setNumTrees in interface RandomForestParamsvalue - (undocumented)public RandomForestClassifier setFeatureSubsetStrategy(String value)
setFeatureSubsetStrategy in interface TreeEnsembleParamsvalue - (undocumented)public RandomForestClassifier copy(ParamMap extra)
ParamsdefaultCopy().copy in interface Paramscopy in class Predictor<Vector,RandomForestClassifier,RandomForestClassificationModel>extra - (undocumented)