Skip to content

Commit

Permalink
More updates
Browse files Browse the repository at this point in the history
  • Loading branch information
odow committed Nov 15, 2023
1 parent b30229d commit 48d6d0e
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions docs/src/tutorials/nonlinear/classifiers.jl
Original file line number Diff line number Diff line change
Expand Up @@ -183,14 +183,7 @@ Plots.scatter!(
markercolor = ifelse.(labels_new .== 1, :blue, :crimson),
markersize = 8,
)
Plots.plot!(
plot,
classifier,
0.0:0.01:2.0;
linewidth = 5,
linestyle = :dashdotdot,
c = :darkblue,
)
Plots.plot!(plot, classifier; linewidth = 5, linestyle = :dashdotdot)

# So our JuMP formulation still produces a classifier, but it mis-classifies
# some of the nonseparable points.
Expand All @@ -213,7 +206,6 @@ Plots.scatter!(
P_active[:, 1],
P_active[:, 2];
shape = :hexagon,
markercolor = :green,
markersize = 8,
markeropacity = 0.5,
)
Expand Down Expand Up @@ -262,13 +254,7 @@ end
# We can check that the dual form has recovered a classifier:

classifier = solve_dual_SVM_classifier(P, labels)
Plots.plot!(
plot,
classifier,
0.0:0.01:2.0;
linewidth = 2,
linestyle = :dash,
)
Plots.plot!(plot, classifier; linewidth = 5, linestyle = :dash)

# ## The kernel method

Expand Down

0 comments on commit 48d6d0e

Please sign in to comment.