I have been using STATA to do some forecasting on stock market data. When I generate the forecasts and look on a graph they are miles off, even though the previous predictions (within sample) are quite close to the real data.

Here is a small bit of the code:

arch dSP, ar(1/3) ma(2/3) arch(1/3) garch(1/3) tarch(1)
set obs `=_N+2'
replace t=_n
predict pSP, dynamic(`N+2')

Lots of the models I have used do similar things, anyone know if this is a viable way to make predictions or am I missing something?

Thanks