klaR (version 0.3-0)

predict.svmlight: Interface to SVMlight

Description

Classifies new observations using the SVM learned by the svmlight-function.

Usage

## S3 method for class 'svmlight':
predict(object, newdata, scal = TRUE, ...)

Arguments

object
Object of class svmlight.
newdata
Data frame (or matrix) of cases to be classified.
scal
Logical, whether to scale membership values via e.scal.
...
...

Value

  • A list with elements class and posterior (scaled, if scal = TRUE).

See Also

svmlight, svm

Examples

Run this code
data(iris)
x <- svmlight(Species ~ ., data = iris)
predict(x, iris)

Run the code above in your browser using DataCamp Workspace