Revised market prediction distributions

January 4, 2011

(This article was first published on Portfolio Probe » R language, and kindly contributed to R-bloggers)

This provides revised plots of the prediction distributions published yesterday.  The previous plots of prediction distributions should be ignored — they are not doing as advertised.

We show the prediction distribution of levels of several equity indices (plus oil price) at the end of 2011 assuming nothing happens.  That is, we’ve taken out market trends and just left random drift.

North America

Figure 1: Dow Jones Industrial Average (USA) 2011 prediction distribution.

Figure 2: S&P 500 (USA) 2011 prediction distribution.

Figure 3: Nasdaq Composite (USA) 2011 prediction distribution.

Figure 4: S&P/TSX Composite (Canada) 2011 prediction distribution.

Figure 5: IPC (Mexico) 2011 prediction distribution.

South America

Figure 6: Bovespa (Brazil) 2011 prediction distribution.

Figure 7: MERVAL (Argentina) 2011 prediction distribution.


Figure 8: FTSE 100 (UK) 2011 prediction distribution.

Figure 9: CAC 40 (France) 2011 prediction distribution.

Figure 10: DAX (Germany) 2011 prediction distribution.

Figure 11: AEX (Netherlands) 2011 prediction distribution.

Figure 12: IBEX 35 (Spain) 2011 prediction distribution.

Figure 13: Euro Stoxx 50 (Europe) 2011 prediction distribution.

The East

Figure 14: Nikkei 225 (Japan) 2011 prediction distribution.

Figure 15: Hang Seng (Hong Kong) 2011 prediction distribution.

Figure 16: Shanghai Composite (China) 2011 prediction distribution.

Figure 17: Straits Times (Singapore) 2011 prediction distribution.

Figure 18: All Ordinaries (Australia) 2011 prediction distribution.

Figure 19: Sensex (India) 2011 prediction distribution.

Oil price

Figure 20: Cushing OK contract 1 (US dollar) 2011 prediction distribution.

The adjustment

While returns are approximately uncorrelated across time, that is not true of the residuals from the trend.  There is significant autocorrelation in the residuals. Taking this phenomenon into account narrows the distributions to be more appetizing and more believable.

The plots are based on a revised simulation that uses blocks of 50 days.  That is, for each simulated year 5 continuous blocks of length 50 are randomly selected from the standardized residuals from the garch model.  With probability one-half the signs of all of the values in a block are switched — either all or none of the signs in the block are switched.

Why the error happened

Missing this would be an easy thing for a novice to do.  However, the problem here was not too little knowledge but too much.

I have done a lot of garch simulations.  And I know that using blocks has very little impact.  But I’ve (naturally) only simulated garch models of returns.  This problem is subtly different.  Autopilot mode was too strong.


Figures may be reproduced with attribution.

Stock index data are from Yahoo.  Oil price data are from the U. S. Energy Information Administration.

Appendix R

You can get the R functions that are used to create the prediction distributions with the R command:

> source('')

The commands to create the prediction distribution plots are in prediction_dist.Rscript.

To leave a comment for the author, please follow the link and comment on their blog: Portfolio Probe » R language. offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Tags: , , ,

Comments are closed.


Mango solutions

RStudio homepage

Zero Inflated Models and Generalized Linear Mixed Models with R

Dommino data lab

Quantide: statistical consulting and training



CRC R books series

Six Sigma Online Training

Contact us if you wish to help support R-bloggers, and place your banner here.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)