I am attempting to calculate the RMSE in-sample value from a GARCH model.
fit.spec1a[[1]]=ugarchspec(variance.model = list(model = "sGARCH",
garchOrder = c(2,0)),
mean.model= list(armaOrder = c(1,0),
include.mean = T),
distribution.model = "sstd")
garch[[i]]<- ugarchfit(data=train.set[[2]][,c(1)],spec = fit.spec1a[[1]],solver="hybrid")
The fitted values appear to fit very well, but are off by exactly one. I am not sure why this is since the length of the test and training data are equal, and couldn't find any documemtation in the 'rugarch' package indicating that fitted values are based on T-1 values. Any help would be greatly appreciated. Below is a plot showing the fitted values (red) and the observed data. .