-
-
Notifications
You must be signed in to change notification settings - Fork 26.5k
Closed
Description
Description
There is an indexing error in make_moons so that when n_samples is odd, x[n_samples // 2] is on the inner circle but y[n_samples // 2] == 0 labeling it as part of the outer circle.
Steps/Code to Reproduce
from sklearn.datasets import make_moons
from numpy import column_stack
column_stack(make_moons(3, shuffle=False))
Expected Results
array([[ 1. , 0. , 0. ],
[ 0. , 0.5, 1. ],
[ 2. , 0.5, 1. ]])
Actual Results
array([[ 1. , 0. , 0. ],
[ 0. , 0.5, 0. ],
[ 2. , 0.5, 1. ]])
Versions
Darwin-15.6.0-x86_64-i386-64bit
Python 3.5.2 |Continuum Analytics, Inc.| (default, Jul 2 2016, 17:52:12)
[GCC 4.2.1 Compatible Apple LLVM 4.2 (clang-425.0.28)]
NumPy 1.11.2
SciPy 0.18.1
Scikit-Learn 0.18
Metadata
Metadata
Assignees
Labels
No labels