MVSML (2022) eqs. (9.34)-(9.37) pp.354-355, dual (9.44)-(9.45)
p.357. C is the box bound of (9.45); the realized slack total is
reported as slack_sum. Delegates to the shared core mirror.
Examples
Svmsl(matrix(c(1, 2, 4, 5, 1, 2, 4, 3), ncol = 2), c(-1, -1, 1, 1), 1)
#> $beta
#> [1] 0.4000001 0.3999998
#>
#> $beta0
#> [1] -2.333333
#>
#> $norm_beta
#> [1] 0.5656854
#>
#> $margin
#> [1] 1.767767
#>
#> $zeta
#> [1] 0.0000000 0.2666667 0.1333335 0.1333332
#>
#> $slack_sum
#> [1] 0.5333333
#>
#> $n_violating
#> [1] 3
#>
#> $n_misclassified
#> [1] 0
#>
#> $alpha
#> [1] 0.000000e+00 1.000000e+00 5.999999e-01 1.316532e-07
#>
#> $support_vectors
#> [1] 2 3
#>
#> $objective
#> [1] 1.44
#>
#> $estimate
#> [1] 1.767767
#>
#> $method
#> [1] "SVM soft margin (MVSML 2022 eqs. 9.34-9.37)"
#>
