trainSVM: Train an SVM.

Description Usage Arguments Value Note

Description

This is the main routine that trains an SVM, e.g. it will make sure that all data is on the disk, create the training arguments and then call the corresponding binary.

Usage

1
2
3
4
trainSVM(method = NULL, trainDataFile = NULL, trainDataX = NULL,
  trainDataY = NULL, extraParameter = "", modelFile = NULL,
  subsamplingRate = NULL, subsamplingMethod = "cutoff", verbose = FALSE,
  timeOut = -1, readModelFile = TRUE, ...)

Arguments

method

name of the SVM method/solver

trainDataFile

Filename to read training data from. This cannot be used at the same time as trainDataX/trainDataY.

trainDataX

Matrix comprising the data. This cannot be used at the same time as trainDataFile.

trainDataY

Vector comprising the labels for the data. This cannot be used at the same time as trainDataFile.

extraParameter

Extra parameters for solver, passed to the createTrainingArguments function of the wrapper.

modelFile

Path to the model file to create. If none specified, a temporary file will be created.

subsamplingRate

Rate to subsample the data.

subsamplingMethod

Method to subsample the data with.

verbose

Be verbose?

timeOut

Value to time out at, so that e.g. solvers that do stall/do an endless loop can be stopped nonetheless.

readModelFile

if TRUE, will read the model back (model is saved in the created object)

...

Further parameters that will be passed to the wrapper.

Value

An SVM Object.

Note

trainDataFile, trainDataX/trainDataY are exclusive parameters, i.e. you cannot specify both.

timeOut might not work on all platforms yet.


aydindemircioglu/SVMBridge documentation built on May 11, 2019, 4:13 p.m.