PredictParams-class: Parameters for Classifier Prediction

Description Constructor Author(s) Examples


Collects the function to be used for making predictions and any associated parameters.


PredictParams() Creates a default PredictParams object. This assumes that the object returned by the classifier has a list element named "class".

PredictParams(predictor, transposeExpression, intermediate = character(0), getClasses, ...) Creates a PredictParams object which stores the function which will do the class prediction and parameters that the function will use.


A function to make predictions with. The first argument must accept the classifier made in the training step. The second argument must accept a matrix of new data.


Set to TRUE if classifier expects features as columns.


Character vector. Names of any variables created in prior stages by runTest that need to be passed to the prediction function.


A function to extract the vector of class predictions from the result object created by predictor.


Other arguments that predictor may use.


Dario Strbenac


predictParams <- PredictParams(predictor = predict, TRUE, getClasses = function(result) result)
# For prediction by trained object created by dlda function.
PredictParams(predictor = function(){}, TRUE, getClasses = function(result) result)
# For when the training function also does prediction and directly returns vector of predictions.

Search within the ClassifyR package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.