-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
cross_val_score can't take scoring parameters without a custom scoring function #5308
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
that is what |
The recommended approach currently might be I agree that in some ways your proposal would be an improvement: the user Its downsides are:
On 25 September 2015 at 05:42, Brian Lange notifications@github.com wrote:
|
@amueller, you're right. But a user is easily tripped up by not realising On 25 September 2015 at 06:56, Andreas Mueller notifications@github.com
|
Ah, I'm just now seeing all the stuff about |
Forgot about the **kwargs. Yes, no currying needed. Still, I think it's a I wonder if one option is to allow make_scorer (or a new scoring=altered_scorer('precision', pos_label=2) or even scoring=make_scorer('precision', pos_label=2) (The need for this could also be avoided by having the greater_is_better On 25 September 2015 at 15:02, Brian Lange notifications@github.com wrote:
|
When using
cross_val_score
, one can choose an averaging method easily using the variousscoring
presets. But if they want to choose a pos_label like those taken byf1
,precision
, andrecall
(to specify scoring with respect to a specific class), they have to define a custom scoring function like this:This obviously isn't that big of a deal, but it would be nice to be able to pass scoring parameters into the function the same way you can pass fit parameters. Like:
I'm happy to contribute code for this but wanted to open an issue first and see what others think/if I'm barking up the wrong tree.
The text was updated successfully, but these errors were encountered: