get_predictions.cl_svm {NeuroDecodeR} | R Documentation |
A classifier (CL) method to train the CL and return predictions
Description
get_predictions
takes a training set and a test set of data. It trains the
CL object on the training set and returns the predictions of the on the test
set. This is a generic function that must be implemented by all CL objects.
This method should not be called directly but instead it is used internally
by the cross-validator (CV) object.
Usage
## S3 method for class 'cl_svm'
get_predictions(cl_obj, training_set, test_set)
Arguments
cl_obj |
The classifier object. |
training_set |
The training set data from one time bin. This is a data
frame where the rows correspond to data from a given trial. There must be a
column called |
test_set |
The test set data from all times. This is a data frame where
the rows correspond to data from a given trial. There must be a column
called |
Value
This method returns a data frame where each row corresponds to a prediction for one of the test points. The columns in this data frame are:
-
test_time: The time bin a test point came from.
-
actual_labels: The actual labels for what happened on a trial.
-
predicted_labels: The predictions that classifier made.
-
decision_vals.___: A set of columns with the decision values for each class.
See Also
cl_max_correlation()
, cl_poisson_naive_bayes()
, cl_svm()