bClassif(train, predClass, predProb, ...)
train
.
This function should return a vector with the predicted classes.
For usage information see Details.train
.
This function should return a matrix with the predicted
probabilities. The matrix, should have:
the number of rows equal to the size of prediction set and
the number of columns equal to the number of possible classes.
For usage information see Details.train
.bClassif
.
train
function is used as follows:model <- train(m, y, ...)
The training data is provided in the two first arguments. Here, m
is a distance matrix between the training instances and y
is a vector
with the classes of those instances. Additional arguments of the classifier can
be passed to train
through the additional arguments (...
)
specified in bClassif
.
The predClass
and predProb
functions are used as follows:
cls <- predClass(model, pm)
cls <- predProb(model, pm)
In both cases, the prediction data is supplied using pm
.
pm
is a distance matrix with the following dimensions:
the number of rows equal to the size of the prediction set and the number
of columns equal to the size of the training set. predClass
returns
a vector with the predicted classes and predProb
returns a matrix
that contains the class probabilities. In this matrix, there is a column
for each class and a row for each instance.