Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[MRG + 1] Fixed impossible min_samples_split value #9520

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

Merged
merged 1 commit into from
Aug 11, 2017

Conversation

diegodlh
Copy link
Contributor

Reference Issue

None

What does this implement/fix? Explain your changes.

Fixed impossible min_samples_split=1 value in User Guide's Ensemble Methods section. Values of 0 and 1 are not allowed.

Any other comments?

None

@NelleV
Copy link
Member

NelleV commented Aug 11, 2017

Hi @diegodlh
I don't think the documentation is wrong, but there is a bug in the validation of the value of min_samples_fit. This is done in the file sklearn/tree/tree.py. Do you want to have a look at how to fix this and add a regression test?
Thanks,

@diegodlh
Copy link
Contributor Author

Hi @NelleV. Thank you for your reply. For a node to be split it makes sense that it has at least two samples. It makes no sense to split a node with only one sample. See @jnothman comment here.

@amueller
Copy link
Member

I think the fix is correct. lgtm

@amueller amueller changed the title [MRG] Fixed impossible min_samples_split value [MRG + 1] Fixed impossible min_samples_split value Aug 11, 2017
@NelleV NelleV merged commit 88f529e into scikit-learn:master Aug 11, 2017
@diegodlh diegodlh deleted the ensemble-doc-fix branch August 11, 2017 23:57
paulha pushed a commit to paulha/scikit-learn that referenced this pull request Aug 19, 2017
AishwaryaRK pushed a commit to AishwaryaRK/scikit-learn that referenced this pull request Aug 29, 2017
jnothman pushed a commit to jnothman/scikit-learn that referenced this pull request Aug 30, 2017
maskani-moh pushed a commit to maskani-moh/scikit-learn that referenced this pull request Nov 15, 2017
jwjohnson314 pushed a commit to jwjohnson314/scikit-learn that referenced this pull request Dec 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants