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

Skip to content

Commit 5d24bae

Browse files
committed
Fixes for flake8 errors
1 parent 587f11a commit 5d24bae

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

examples/svm/plot_separating_hyperplane.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@
3737
Z = clf.decision_function(xy).reshape(XX.shape)
3838

3939
# plot decision boundary and margins
40-
ax.contour(XX, YY, Z, colors='k', levels=[-1, 0, 1], alpha=0.5, linestyles=['--', '-', '--'])
40+
ax.contour(XX, YY, Z, colors='k', levels=[-1, 0, 1], alpha=0.5,
41+
linestyles=['--', '-', '--'])
4142
# plot support vectors
42-
ax.scatter(clf.support_vectors_[:, 0], clf.support_vectors_[:, 1], s=100, linewidth=1, facecolors='none')
43+
ax.scatter(clf.support_vectors_[:, 0], clf.support_vectors_[:, 1], s=100,
44+
linewidth=1, facecolors='none')

examples/svm/plot_separating_hyperplane_unbalanced.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,4 +73,5 @@
7373
# plot decision boundary and margins for weighted classes
7474
b = ax.contour(XX, YY, Z, colors='r', levels=[0], alpha=0.5, linestyles=['-'])
7575

76-
plt.legend([a.collections[0], b.collections[0]], ["non weighted", "weighted"], loc="upper right")
76+
plt.legend([a.collections[0], b.collections[0]], ["non weighted", "weighted"],
77+
loc="upper right")

0 commit comments

Comments
 (0)