Skip to content

Commit

Permalink
Merge pull request #37 from DilumAluthge/patch-1
Browse files Browse the repository at this point in the history
Fix ScikitLearn API regression example
  • Loading branch information
mpastell authored Jul 12, 2018
2 parents 5b3d530 + 29274f4 commit 37fbf12
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ yp = predict(model, instances[2:2:end, :])
#epsilon-regression
whiteside = RDatasets.dataset("MASS", "whiteside")
X = Array(whiteside[:Gas])
if typeof(X) <: AbstractVector
X = reshape(X, (length(X),1))
end
y = Array(whiteside[:Temp])
svrmod = fit!(EpsilonSVR(cost = 10., gamma = 1.), X, y)
yp = predict(svrmod, X)
Expand Down

0 comments on commit 37fbf12

Please sign in to comment.