9

Even if I don't define the scoring parameter, it scores and makes a decision for best estimator, but documentation says the default value for scoring is "None", so what is it using to score when I don't define a metric or list of metrics?

TwoPointNo
  • 91
  • 1
  • 2

1 Answers1

6

From the User Guide:

By default, parameter search uses the score function of the estimator to evaluate a parameter setting. These are the sklearn.metrics.accuracy_score for classification and sklearn.metrics.r2_score for regression...

Ben Reiniger
  • 11,094
  • 3
  • 16
  • 53
  • Thank you, I didn't know they had defaults in function of classificator or regressor, just seeing "score" was driving me mad. Deep dive into he documentation is needed. – TwoPointNo May 11 '21 at 23:29
  • Each estimator's `score` docstring says what it measures. But classifiers and regressors consistently use accuracy and r2, respectively. – Ben Reiniger May 12 '21 at 01:13