Hello,

I would like to use a parametric TS model and predictor as benchmark to
compare against other ML methods I'm employing. I currently build a simple
e.g. ARIMA model using the convenient auto.arima function like this:

library(forecast)
df <- read.table("/Users/bravegag/data/myts.dat")
# btw my test data doesn't have seasonality but periodicity so the value
# 2 is arbitrarily set, using a freq of yearly or 1 would make unhappy some
# R ts functions
tsdata <- ts(df$signal, freq=2)
arimamodel <- auto.arima(tsdata, max.p=15, max.q=10, stationary=FALSE,
ic="bic", stepwise=TRUE, seasonal=FALSE, parallel=FALSE, num.cores=4,
trace=TRUE, allowdrift=TRUE)
arimapred <- forecast.Arima(arimamodel, h=20)
plot(arimapred)

The problem is that the forecast.Arima function is apparently doing a "free
run" i.e. it uses the forecast(t+1) value as input to compute forecast(t+2)
and I'm instead interested in a prediction mode where it always use the
observed tsdata(t+1) value to predict forecast(t+2), the observed
tsdata(t+2) to predict forecast(t+3) and so on.

Can anyone please advice how to achieve this?

TIA,
Best regards,
Giovanni

	[[alternative HTML version deleted]]

