From 71e23af280652c607bf8c9b8c6d341eca3edb25c Mon Sep 17 00:00:00 2001 From: Bharat123Rox Date: Wed, 13 Mar 2019 23:22:32 +0530 Subject: [PATCH] Add scoring metric info in cross_val_score --- sklearn/model_selection/_validation.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/sklearn/model_selection/_validation.py b/sklearn/model_selection/_validation.py index 016e113e33740..6be8701fa2ebb 100644 --- a/sklearn/model_selection/_validation.py +++ b/sklearn/model_selection/_validation.py @@ -281,7 +281,13 @@ def cross_val_score(estimator, X, y=None, groups=None, scoring=None, cv='warn', scoring : string, callable or None, optional, default: None A string (see model evaluation documentation) or a scorer callable object / function with signature - ``scorer(estimator, X, y)``. + ``scorer(estimator, X, y)`` which should return only + a single value. + + Similar to :func:`cross_validate` + but only a single metric is permitted. + + If None, the estimator's default scorer (if available) is used. cv : int, cross-validation generator or an iterable, optional Determines the cross-validation splitting strategy.