svm: svm

Description Usage Arguments Details Value Communication References See Also Examples

View source: R/svm.r

Description

Support vector machine. The internals are nearly identical to that of the logistic regression fitter, except that here we use the "hinged loss".

Usage

1
svm(x, y, maxiter = 500)

Arguments

x, y

The input data x and response y. Each must be a shaq, and each must be distributed in an identical fashion. See the details section for more information.

maxiter

The maximum number of iterations.

Details

The optimization uses Nelder-Mead.

Both of x and y must be distributed in an identical fashion. This means that the number of rows owned by each MPI rank should match, and the data rows x and response rows y should be aligned. Additionally, each MPI rank should own at least one row. Ideally they should be load balanced, so that each MPI rank owns roughly the same amount of data.

Value

The return is the output of an optim() call.

Communication

The communication consists of an allreduce of 1 double (the local cost/objective function value) at each iteration of the optimization.

References

Efron, B. and Hastie, T., 2016. Computer Age Statistical Inference (Vol. 5). Cambridge University Press.

See Also

glm

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
library(kazaam)
comm.set.seed(1234, diff=TRUE)

x = ranshaq(rnorm, 10, 3)
y = ranshaq(function(i) sample(0:1, size=i, replace=TRUE), 10)

fit = svm(x, y)
comm.print(fit)

finalize()

## End(Not run)

RBigData/kazaam documentation built on Nov. 9, 2021, 9:09 a.m.