In case you thought volatility is isolated, the charts below give you an idea of how volatility leads to more volatility – duh! Knowing this doesn’t license you to print money, life would be way too boring if that was the case. The problem is not knowing that volatility cluster it is that we have no idea how long we will stay in a low or high volatility environment and its amplitude. In essence the billion dollar question is identifying when an environment regime shifts.
There is a ton of research in this area, and I have to confess I am attracted to the hidden Markov chain process in the shorter time horizons. Later in the year I hope to share some of my research into this subject. Let’s get back to the clustering:
In the top chart I look at the S&P500 on a rolling 100 days with 2% or more moves, and the bottom chart shows the Shanghai Stock Index which took a 7% bath yesterday, and with GDP numbers coming out later today promises to provide further fireworks. What I can say about the comparative 2 charts is that China is starting to look like its entering a more volatile period ahead of the US.
For those interested in the R code I have included it as well. (Hat tip to John Hussman for the graphic idea, I wish my code were more elegant, but I think it does the job, ignore the errors about my labelling).
require(quantmod) require(PerformanceAnalytics) #get the data getSymbols('^SSEC', from='1990-01-01') #lets look at it from 1990 to 2015 #spy <- SPY['1990/2015'] Shang<- SSEC['1990/2015'] #our baseline, unfiltered results ret <- ROC(Cl(Shang)) #our comparision, filtered result filter.d <- Lag(ifelse(ret < -0.02, 1, 0)) drops<- rollapply(filter.d==1,100,sum) filter.g <- Lag(ifelse(ret < 0.02, 1, 0)) gain<- rollapply(filter.g==1,100,sum) plot(drops, main = "Drop and Gain Clustering", sub = "sum of 2% movements over 100 prior days", ylab ="drops") par(new=T) plot(gain, main = "Drop and Gain Clustering", labels = FALSE, col = "red") axis(side =4) mtext("gains", side = 4)