### Dummy Classifier and Dummy Regressor Metrics¶

• When doing supervised learning, compare your estimator against a simple example as a sanity test. DummyClassifier provides several strategies for this.

• stratified: generates random predictions by respecting the training set class distribution.

• most_frequent: always predicts the most frequent label in the training set.

• prior: always predicts the class that maximizes the class prior (like most_frequent) and predict_proba returns the class prior.

• uniform: generates predictions uniformly at random.

• constant always predicts a constant user-specified label.

• Note: the predict method completely ignores the input data.

• SVC doesn’t do much better than a dummy classifier. Change the kernel and re-run:
• DummyRegressor also implements four rules of thumb for regression:

• mean: predicts the mean of the training targets.

• median: predicts the median of the training targets.

• quantile: predicts a user provided quantile of the training targets.

• constant: predicts a constant user-specified value.