October 2017
Intermediate to advanced
330 pages
7h 7m
English
import numpy as np from sklearn.model_selection import train_test_splitimport matplotlib.pyplot as plt# We will be using make_circles from scikit-learnfrom sklearn.datasets import make_circlesSEED = 2017
# We create an inner and outer circleX, y = make_circles(n_samples=400, factor=.3, noise=.05, random_state=2017)outer = y == 0inner = y == 1
plt.title("Two Circles")plt.plot(X[outer, 0], X[outer, 1], "ro")plt.plot(X[inner, 0], X[inner, 1], "bo")plt.show()

Read now
Unlock full access