Skip to main content

LinearSVR

#include <Skigen/SVM>

template <typename Scalar = double>
class Skigen::LinearSVR(C=1.0, epsilon=0, loss=Loss::EpsilonInsensitive, tol=1e-4, max_iter=1000, fit_intercept=true, random_state=std::nullopt)

Linear epsilon-insensitive Support Vector Regression.

Mirrors sklearn.svm.LinearSVR.

Solves minw12w2+CiL(yiwxib)\min_w \tfrac{1}{2}\|w\|^2 + C \sum_i L(y_i - w \cdot x_i - b) where LL is the ϵ\epsilon-insensitive loss (loss="epsilon_insensitive", the sklearn default) — the residual contributes only when r>ϵ|r| > \epsilon.



Attributes:

  • C : Scalar

  • epsilon : Scalar

  • coef : RowVectorType

  • intercept : Scalar


Methods

SKIGEN_PARAMS()


fit(X, y)

Fit from a sparse design matrix (densifies internally).


predict(X)


score(X, y)