Create predictions for TFT models
predict.tft.RdCreate predictions for TFT models
Usage
# S3 method for tft
predict(object, new_data, type = "numeric", mode = "horizon", step = NULL, ...)Arguments
- object
a model object for which prediction is desired.
- new_data
A
data.frame()containing a dataset to generate predictions for. In general it's used to pass static and known information to generate forecasts.- type
Currently only
'numeric'is accepted but this might change in the future if we end up supporting classification.- mode
Prediction mode. If
'horizon'predict will generate a single multi-horizon prediction. This is mostly sueful when creating forecasts for the time frame right after the model has been trained. If'full'then predictions are created for every possible time step (with a possiblestep) argument. Whenmode='horizon'(default) only the prediction columns are returned. Whenmode='full'all columns fromnew_dataare returned as the result might have more lines than innew_databecause it's potentially possible to generate different predictions for the same time-step.- step
Step for predictions when using
mode='full'.- ...
additional arguments affecting the predictions produced.