Learn Before
  • sklearn.dummy.DummyClassifier

DummyClassifier strategy parameter

The strategy parameter determines which strategy the DummyClassifier will use to predict a class label.

  • strategy = "stratified". The DummyClassifier makes random predictions based on the distribution of the training data.
  • strategy = "uniform". DummyClassifier will generate predictions uniformly at random.
  • strategy = "most_frequent". DummyClassifier will always predict the most frequent class label in the training dataset.
  • strategy = "constant". This is most often used when classifying non-majority class labels. The DummyClassifier will always predict a constant label, which is provided by the user.

0

1

5 years ago

Tags

Data Science

Related
  • DummyClassifier strategy parameter

  • sklearn.dummy.DummyRegressor