pathClass (version 0.9.3)

predict.networkBasedSVM: Predict Method for Network-based SVM Fits...

Description

Predict Method for Network-based SVM Fits

Usage

## S3 method for class 'networkBasedSVM':
predict(object, newdata, ...)

Arguments

object
a fitted object of class inheriting from 'networkBasedSVM'
newdata
a matrix with variables to predict
...
currently ignored.

Value

  • the predictions.

Details

Obtains predictions from a fitted networkBasedSVM object.

Examples

Run this code
library(pathClass)
data(example_data)
matched <- matchMatrices(x=x, adjacency=adjacency.matrix, mapping=mapping)
ad.list <- as.adjacencyList(matched$adjacency)
fit = fit.networkBasedSVM(matched$x[1:5,], y[1:5], DEBUG=TRUE,  adjacencyList=ad.list, lambdas=10^(-1:2), sd.cutoff=50)
predict(fit, newdata=matched$x[6:10,])

Run the code above in your browser using DataCamp Workspace