I would like to compare one-step ahead forecasts on a given time series for ARIMA and UCM (using KFAS library). I have split my time series in train and validation, that I will use to understand which model performs better.
After reading the anwswer to this post: Difference between first one-step ahead forecast and first forecast from fitted model, I understood the following explanation for Arima:
So fitted(fit) gives one-step forecasts of observations 1, 2, ... It is possible to produce a "forecast" for observation 1 as a forecast is simply the expected value of that observation given the model and any preceding history.
fitted(refit) gives one-step forecasts of observations 401, 402, .... So it uses the model estimated on observations 1...400, but it uses the data from time 401...500.
What I don't understand is how to make one-step forecasts on observations 401, 402, .. using data from time 1.. 400 and (possibly?) the calculated forecasts up to previous time. I want to pretend not to know data 401..500 and compare the one-step forecasts with them.
Thank you for any help on this.