pred {predtoolsTS} | R Documentation |
Predictions
Description
Performs predictions over a trained model.
Usage
pred(model = NULL, n.ahead = 20, tserie = NULL, predictions = NULL)
Arguments
model |
A |
n.ahead |
Number of values to predict ahead of the end of the original time serie. Default value is 20. Must ve lower than 100. |
tserie |
A |
predictions |
A |
Details
Predicts future values over a "modl" object which can be ARIMA or data mining, and returns the predictions. Data mining predictions start right after the last value contained in the training data, so they overlap with the end of the original.
The object contains only two time series: the original one and the predictions. You can just set these series aswell.
Value
A list is returned of class pred
containing:
tserie |
Original time serie. |
predictions |
Time serie with the predictions. |
Author(s)
Alberto Vico Moreno
See Also
modl
pred.arima
,
pred.dataMining
,
pred.compareModels
Examples
prediction <- pred(model=modl(prep(AirPassengers)),n.ahead=25)
pred(tserie=prediction$tserie, predictions=prediction$predictions)