How is the score of GridsearchCV calculated? Is the score a percentage? Does this mean higher is a better?
Asked
Active
Viewed 3,201 times
1 Answers
4
The score is based on the scorer defined in the scoring argument. Meaning, the scorer can be any of the default metrics, such as precision, accuracy or F1-score (e.g., this); or a custom scorer. For a scorer (by convention), higher value is better. The value is not necessarily a percentage, but is often normalized between 0 and 1.
Shayan Shafiq
- 1,012
- 4
- 11
- 24
Felix Z.
- 172
- 5
-
I create a Gradient Boost Regressor with a GridSearchcv but dont define the score. Whta does the score mean by default? – ml_learner Feb 11 '20 at 13:43
-
2If None, the estimator’s score method is used. This means in your case the Gradient Boost Regressor default scorer is used (that is coefficient R^2) – Felix Z. Feb 11 '20 at 13:48
-
and r² is not a percentage? – ml_learner Feb 11 '20 at 14:00
-
2By convention, we use word `score` when higher is better. We use word `loss` when less is better. When you don't have any particular in mind, use `metric`. – Piotr Rarus Feb 11 '20 at 14:53
-
1@ml_learner r2 is not percentage (and it's not r-squared). It's 'kinda' normalized, but you can use it to compare models just fine. 1.0 - is perfect model 0.0 - this is constant answer model <0.0 - model goes wrong – Piotr Rarus Feb 11 '20 at 14:54
-
@PiotrRarus-ReinstateMonica I didn't know about the score / loss convention, but seems logic. Changed the answer accordingly. – Felix Z. Feb 11 '20 at 16:39