predict.supervised_model {fastTextR} | R Documentation |
Predict values based on a previously trained model.
## S3 method for class 'supervised_model' predict(object, newdata = character(), newdata_file = "", result_file = "", k = 1L, prob = FALSE, ...)
object |
an object inheriting from |
newdata |
a character vector giving the new data. |
newdata_file |
a character string giving the location of to the new data. |
result_file |
a character string naming a file. |
k |
an integer giving the number of labels to be returned. |
prob |
a logical if true the probabilities are also returned. |
... |
currently not used. |
NULL
if a 'result_file'
is given otherwise
if 'prob'
is true a data.frame
with the predicted labels
and the corresponding probabilities, if 'prob'
is false a
character vector with the predicted labels.
## Not run: predict(object, newdata) ## End(Not run)