asreview.models.classifiers.RandomForestClassifier

class asreview.models.classifiers.RandomForestClassifier(n_estimators=100, max_features=10, class_weight=1.0, random_state=None)[source]

Random forest classifier (rf).

The Random Forest classifier is an implementation based on the sklearn Random Forest classifier.

Parameters:
  • n_estimators (int, default=100) – The number of trees in the forest.

  • max_features (int, default=10) – Number of features in the model.

  • class_weight (float, default=1.0) – Class weight of the inclusions.

  • random_state (int or asreview.utils.SeededRandomState, default=None) – Controls both the randomness of the bootstrapping of the samples used when building trees and the sampling of the features to consider when looking for the best split at each node.

Attributes

default_param

Get the default parameters of the model.

label

name

param

Get the (assigned) parameters of the model.

Methods

fit(X, y)

Fit the model to the data.

full_hyper_space()

hyper_space()

predict_proba(X)

Get the inclusion probability for each sample.