Lets generate random data
x y
1 1 3
2 2 4
3 3 5
4 4 4
5 5 8
6 6 10
Generate Linear Map
Fit a SVM model
Call:
svm(formula = y ~ x, data = train)
Parameters:
SVM-Type: eps-regression
SVM-Kernel: radial
cost: 1
gamma: 1
epsilon: 0.1
Number of Support Vectors: 9
Use PREDICTIONS ON THE DATA
Plot the predictios and the plot to see our model fit
MSE Comparison
[1] 2.696281
[1] 3.832974