powered by
data.frame
Rbind original and predicted time-series-like instances as fortified data.frame
rbind_ts( data, original, ts.connect = TRUE, index.name = "Index", data.name = "Data" )
Predicted/forecasted ts instance
ts
Original ts instance
Logical frag indicates whether connects original time-series and predicted values
Specify column name for time series index
Specify column name for univariate time series data. Ignored in multivariate time series.
if (FALSE) { predicted <- predict(stats::HoltWinters(UKgas), n.ahead = 5, prediction.interval = TRUE) rbind_ts(predicted, UKgas, ts.connect = TRUE) }
Run the code above in your browser using DataLab