DecisionTree.AdaBoostStumpClassifierType
AdaBoostStumpClassifier(; n_iterations::Int=0)

Adaboosted decision tree stumps. See DecisionTree.jl's documentation

Hyperparameters:

  • n_iterations: number of iterations of AdaBoost
  • rng: the random number generator to use. Can be an Int, which will be used to seed and create a new random number generator.

Implements fit!, predict, predict_proba, get_classes

DecisionTree.DecisionTreeClassifierType
DecisionTreeClassifier(; pruning_purity_threshold=0.0,
                       max_depth::Int=-1,
                       min_samples_leaf::Int=1,
                       min_samples_split::Int=2,
                       min_purity_increase::Float=0.0,
                       n_subfeatures::Int=0,
                       rng=Random.GLOBAL_RNG)

Decision tree classifier. See DecisionTree.jl's documentation

Hyperparameters:

  • pruning_purity_threshold: (post-pruning) merge leaves having >=thresh combined purity (default: no pruning)
  • max_depth: maximum depth of the decision tree (default: no maximum)
  • min_samples_leaf: the minimum number of samples each leaf needs to have (default: 1)
  • min_samples_split: the minimum number of samples in needed for a split (default: 2)
  • min_purity_increase: minimum purity needed for a split (default: 0.0)
  • n_subfeatures: number of features to select at random (default: keep all)
  • rng: the random number generator to use. Can be an Int, which will be used to seed and create a new random number generator.

Implements fit!, predict, predict_proba, get_classes

DecisionTree.DecisionTreeRegressorType
DecisionTreeRegressor(; pruning_purity_threshold=0.0,
                      max_depth::Int-1,
                      min_samples_leaf::Int=5,
                      min_samples_split::Int=2,
                      min_purity_increase::Float=0.0,
                      n_subfeatures::Int=0,
                      rng=Random.GLOBAL_RNG)

Decision tree regression. See DecisionTree.jl's documentation

Hyperparameters:

  • pruning_purity_threshold: (post-pruning) merge leaves having >=thresh combined purity (default: no pruning)
  • max_depth: maximum depth of the decision tree (default: no maximum)
  • min_samples_leaf: the minimum number of samples each leaf needs to have (default: 5)
  • min_samples_split: the minimum number of samples in needed for a split (default: 2)
  • min_purity_increase: minimum purity needed for a split (default: 0.0)
  • n_subfeatures: number of features to select at random (default: keep all)
  • rng: the random number generator to use. Can be an Int, which will be used to seed and create a new random number generator.

Implements fit!, predict, get_classes

DecisionTree.RandomForestClassifierType
RandomForestClassifier(; n_subfeatures::Int=-1,
                       n_trees::Int=10,
                       partial_sampling::Float=0.7,
                       max_depth::Int=-1,
                       rng=Random.GLOBAL_RNG)

Random forest classification. See DecisionTree.jl's documentation

Hyperparameters:

  • n_subfeatures: number of features to consider at random per split (default: -1, sqrt(# features))
  • n_trees: number of trees to train (default: 10)
  • partial_sampling: fraction of samples to train each tree on (default: 0.7)
  • max_depth: maximum depth of the decision trees (default: no maximum)
  • min_samples_leaf: the minimum number of samples each leaf needs to have
  • min_samples_split: the minimum number of samples in needed for a split
  • min_purity_increase: minimum purity needed for a split
  • rng: the random number generator to use. Can be an Int, which will be used to seed and create a new random number generator. Multi-threaded forests must be seeded with an Int

Implements fit!, predict, predict_proba, get_classes

DecisionTree.RandomForestRegressorType
RandomForestRegressor(; n_subfeatures::Int=-1,
                      n_trees::Int=10,
                      partial_sampling::Float=0.7,
                      max_depth::Int=-1,
                      min_samples_leaf::Int=5,
                      rng=Random.GLOBAL_RNG)

Random forest regression. See DecisionTree.jl's documentation

Hyperparameters:

  • n_subfeatures: number of features to consider at random per split (default: -1, sqrt(# features))
  • n_trees: number of trees to train (default: 10)
  • partial_sampling: fraction of samples to train each tree on (default: 0.7)
  • max_depth: maximum depth of the decision trees (default: no maximum)
  • min_samples_leaf: the minimum number of samples each leaf needs to have (default: 5)
  • min_samples_split: the minimum number of samples in needed for a split
  • min_purity_increase: minimum purity needed for a split
  • rng: the random number generator to use. Can be an Int, which will be used to seed and create a new random number generator. Multi-threaded forests must be seeded with an Int

Implements fit!, predict, get_classes

DecisionTree.apply_adaboost_stumps_probaMethod
apply_adaboost_stumps_proba(stumps::Ensemble, coeffs, features, labels::AbstractVector)

computes P(L=label|X) for each row in features. It returns a N_row x n_labels matrix of probabilities, each row summing up to 1.

col_labels is a vector containing the distinct labels (eg. ["versicolor", "virginica", "setosa"]). It specifies the column ordering of the output matrix.

DecisionTree.apply_forest_probaMethod
apply_forest_proba(forest::Ensemble, features, col_labels::AbstractVector)

computes P(L=label|X) for each row in features. It returns a N_row x n_labels matrix of probabilities, each row summing up to 1.

col_labels is a vector containing the distinct labels (eg. ["versicolor", "virginica", "setosa"]). It specifies the column ordering of the output matrix.

DecisionTree.apply_tree_probaMethod
apply_tree_proba(::Node, features, col_labels::AbstractVector)

computes P(L=label|X) for each row in features. It returns a N_row x n_labels matrix of probabilities, each row summing up to 1.

col_labels is a vector containing the distinct labels (eg. ["versicolor", "virginica", "setosa"]). It specifies the column ordering of the output matrix.