Class: Strategy

eclairjs/mllib/tree/configuration. Strategy

new Strategy(algo, impurity, maxDepth, numClasses, maxBins, quantileCalculationStrategy, categoricalFeaturesInfo, minInstancesPerNode, minInfoGain, maxMemoryInMB, subsamplingRate, useNodeIdCache, checkpointInterval)

Parameters:
Name Type Description
algo Algo
impurity Impurity
maxDepth number
numClasses number
maxBins number
quantileCalculationStrategy QuantileStrategy
categoricalFeaturesInfo Map
minInstancesPerNode number
minInfoGain number
maxMemoryInMB number
subsamplingRate number
useNodeIdCache boolean
checkpointInterval number
Source:

Methods

(static) defaultStategy(algo) → {module:eclairjs/mllib/tree/configuration.Strategy}

Parameters:
Name Type Description
algo Algo
Source:
Returns:
Type
module:eclairjs/mllib/tree/configuration.Strategy

(static) defaultStrategywithAlgo(algo) → {module:eclairjs/mllib/tree/configuration.Strategy}

Construct a default set of parameters for DecisionTree
Parameters:
Name Type Description
algo Algo Algo.Classification or Algo.Regression
Source:
Returns:
Type
module:eclairjs/mllib/tree/configuration.Strategy

(static) defaultStrategywithstring(algo) → {module:eclairjs/mllib/tree/configuration.Strategy}

Construct a default set of parameters for DecisionTree
Parameters:
Name Type Description
algo string "Classification" or "Regression"
Source:
Returns:
Type
module:eclairjs/mllib/tree/configuration.Strategy

copy() → {module:eclairjs/mllib/tree/configuration.Strategy}

Returns a shallow copy of this instance.
Source:
Returns:
Type
module:eclairjs/mllib/tree/configuration.Strategy

isMulticlassClassification() → {boolean}

Source:
Returns:
Type
boolean

isMulticlassWithCategoricalFeatures() → {boolean}

Source:
Returns:
Type
boolean

setAlgo(algo)

Sets Algorithm using a String.
Parameters:
Name Type Description
algo string
Source:

setCategoricalFeaturesInfo(categoricalFeaturesInfo)

Sets categoricalFeaturesInfo using a JavaScript object with simple key/value map.
Parameters:
Name Type Description
categoricalFeaturesInfo object simple key/value map
Source:

setMaxDepth(num)

Parameters:
Name Type Description
num integer
Source:

setNumClasses(num)

Parameters:
Name Type Description
num integer
Source: