Predict over the new data instances using the trained model.

pompredict(model, test)

Arguments

model

A trained POM model.

test

Numeric test data without labels.

Value

A list containing at the first position the projected values per instance per class and at the second position the predicted label for the values.

Examples

dattrain<-read.table("train_balance-scale.0", sep=" ")
#> Warning: cannot open file 'train_balance-scale.0': No such file or directory
#> Error in file(file, "rt"): cannot open the connection
fit<-pomfit(dattrain[,-ncol(dattrain)],as.factor(dattrain[,ncol(dattrain)]),"logistic")
#> Error in is.factor(x): object 'dattrain' not found
dattest<-read.table("test_balance-scale.0", sep=" ")
#> Warning: cannot open file 'test_balance-scale.0': No such file or directory
#> Error in file(file, "rt"): cannot open the connection
predictions<-pompredict(fit,dattest[,-ncol(dattest)])
#> Error in pompredict(fit, dattest[, -ncol(dattest)]): object 'fit' not found
projections<-predictions[[1]]
#> Error in eval(expr, envir, enclos): object 'predictions' not found
predictedLabels<-predictions[[2]]
#> Error in eval(expr, envir, enclos): object 'predictions' not found