strategies

Mean-Reversion Volatility Filters Part Two: Since 2011

On my previous post, Mean-Reversion Volatility Filters, I used a dynamic volatility filter to filter out trades within  a short-term mean reversion system. I came to the conclusion that low vol was conducive for short term mean reversion performance. However, it’s commonly discussed how the market has shifted dynamics some time after the 2007-2008 financial crisis. In this post I revisit the tests ran in my previous post, testing from 1/1/2011 – 4/28/2013 rather than 1/1/1995 – 4/28/2013. The charts displayed below are 10-trade moving average of % profit from 1/1/1995-4/28/2013.

Results

IBS

Rules (Base-Case):

  • Buy if 3-Day IBS < 40
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.53%

IBS Base Case 10-Trade MA

Rules (High Vol):

  • Buy if 3-Day IBS < 40 AND HV(5) > HV(20)
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.68%

IBS High Vol 10-Trade MA

Rules (Low Vol):

  • Buy if 3-Day IBS < 40 and HV(5) < HV(20)
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.38%

IBS Low Vol 10-Trade MA

RSI

Rules (Base-Case):

  • Buy if 2-Day RSI< 50
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.21%

RSI Base Case 10-Trade MA

Rules(High Vol):

  • Buy if  2-Day RSI< 50 and HV(5) > HV(20)
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.40%

RSI High Vol 10-Trade MA

Rules(Low Vol):

  • Buy if  2-Day RSI< 50 and HV(5) < HV(20)
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.10%

RSI Low Vol 10-Trade MA

Conclusion

Without looking at the charts, it may seem like post 2011, this volatility filter, like many strategies, has completely changed. However after looking at the charts of a rolling 10-trade moving average of % profit. the results become more inconclusive. It seems much more likely that the short term test results are due to unrepresentative and small sample size, rather than a change in volatility filter performance.

 

Mean-Reversion Volatility Filters

Due to the result’s of this MarketSci post, which imply that short-term mean reversion performs better during low volatility versus high volatility, I decided to revisit volatility filters. In Mean-Reversion within Regimes, I previously concluded that high volatility, not low volatility was more conducive to mean-reversion strategies. To test for low volatility/high volatility I decided to use a different filter. Last time I used a static test (60-Day Historical Volatility > 0.01 = High Volatility, <0.01 = Low Volatility). This time I will use a more dynamic filter, which compares short-term volatility to mid-term volatility.

Results

  • Testing on SPY from 1/1/1995- 4/28/2013

IBS

Rules (Base-Case):

  • Buy if 3-Day IBS < 40
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.56%

Rules (High Vol):

  • Buy if 3-Day IBS < 40 AND HV(5) > HV(20) 
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.39%

Rules (Low Vol):

  • Buy if 3-Day IBS < 40 and HV(5) < HV(20)
  • Sell if 3-Day IBS > 40
  • Avg. Trade: 0.68%

RSI

Rules (Base-Case):

  • Buy if 2-Day RSI< 50
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.32%

Rules(High Vol):

  • Buy if  2-Day RSI< 50 and HV(5) < HV(20)
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.27%

Rules(Low Vol);

  • Buy if  2-Day RSI< 50 and HV(5) < HV(20)
  • Sell if 2-Day RSI > 50
  • Avg. Trade: 0.37%

Conclusion

It seems from this, in combination with my previous conclusion from Mean-Reversion within Regimes, that the specific filter used for volatility has a large influence on profitability. One thing I realized is that there may be different exposures for low vol vs high vol (meaning that a high volatility filter may allow for more trades, resulting in a higher CAGR) which could result in the discrepancy in results (that is why I used Avg. Trade rather than CAGR this time), but even after re-running the different tests under the same conditions, high vol had a higher Avg. Trade vs low vol.

RSI of Volatility Indicator

It’s common knowledge by now that low volatility is conducive to bullish behavior and high volatility is conducive to bearish behavior. To create a trading system that would short bursts of high volatility and buy short periods of low volatility I took the 5-day RSI of the daily Close-Open Range.

Edit: Commenter Ramiro called to my attention that I do not actually take the RSI of the Close-Open range, just the Close-Open. I’m actually measuring the magnitude AND the direction, meaning that this is just simply another mean-reversion indicator, NOT a volatility indicator.

To turn my indicator into a trading system, I optimized buy and sell threshold (1-100) on SPY from 1/1/2000 – 12/29/2012. I optimized a long-only version of the system. Here is a picture of the 3D optimization with CAGR on the z-axis.

RSI 5-Day Extreme Close Range Optimization Buy Thresh 1-1-2000 - 12-29-2012

Buy Threshold

RSI 5-Day Extreme Close Range Optimization Sell Thresh 1-1-2000 - 12-29-2012

Sell Threshold

There is a small hilly region near the middle. I chose 40 as my buy threshold and 55 as my sell threshold since they are round numbers within the hilly region.

One thing peculiar that I noticed, but can’t seem to explain is that there are two of every set of system statistics, and the only difference is 1) the parameters of buy/sell threshold are switched and 2) the number of trades:

RSI 5-Day Extreme Close Range Optimization Peculiar 1-1-2000 - 12-29-2012

After some pondering I noticed that it might be because some of the buying is negligible. For example, if we have a 40/60 threshold then we will buy if the RSI is at 30, regardless if the 40 or the 60 is the buy threshold. However, the problem that I came across is that if the RSI is at 30 today, but is at 50 tomorrow, then we will buy & hold for a 40/60 threshold (buy when RSI < 40 and sell when RSI > 60), but we will buy & sell for a 60/40 threshold ( buy when RSI < 60 and sell when RSI > 40). I can’t seem to figure out why there each set of system statistics has a twin.

Next, I optimized the short and cover threshold (1-100) on the same data, using a short-only version of the system. Here is a picture of the 3D optimization with CAGR on the z-axis.

RSI 5-Day Extreme Close Range Optimization Short Thresh 1-1-2000 - 12-29-2012

Short Threshold

RSI 5-Day Extreme Close Range Optimization Cover Thresh 1-1-2000 - 12-29-2012

Cover Threshold

There is another small hilly region near the middle. I chose 55 as my short threshold and 40 as my cover threshold since they are round numbers within the hilly region.

The peculiarity of the long only side of the system does not seem to exist on the short side.

Here is the optimized equity curve with a system of the following rules:

  • Buy RSI < 40
  • Sell RSI > 55
  • Cover RSI < 40
  • Short RSI > 55

RSI 5-Day Extreme Close Range Optimization Equity Curve 1-1-2000 - 12-29-2012

The equity curve looks similar to that of many mean-reversion trading systems.

To check for robustness, I tested this system on multiple ETFs from 1/1/2000 – 12/29/2012.

RSI 5-Day Extreme Close Range ETF Scan 1-1-2000 - 12-29-2012

For further robustness, I tested this system using different lengths of RSI on SPY.

RSI 5-Day Extreme Close Range Length Optimization 1-1-2000 - 12-29-2012

One of my concerns is the success of the system since 2010, since many systems seemed to have performed differently or even completely stopped working from around that period. Here is the performance of the system on multiple markets from 1/1/2010 – 12/29/2012

RSI 5-Day Extreme Close Range ETF Scan 1-1-2010 - 12-29-2012

Cumulative IBS Indicator

Inspired by Larry Connors’ Cumulative RSI(2) (found in this post), and the results of my Cumulative DV2 (found in this post) I decided to test out how a Cumulative IBS indicator would work. The formula for IBS can be found here, and the cumulative IBS is the X-day simple moving average of the IBS. This is a frictionless test on SPY from 1/1/2000 – 12/26/2012. I tested the cumulative IBS using default parameters from the original post I found over IBS (Long if IBS < 45 & Short if IBS > 95).

Equity curves for cumulative 1-9 day IBS. Starts at 1-day in the top left and ends at 9-day on the bottom right. It counts from left to right, meaning that the top middle picture is the cumulative 2-day IBS.

Cum 1-9Day IBS 45 95 1-1-2000 - 12-26-12

Equity curves for cumulative 10-18 day IBS. Follows same structure as above.

Cum 9-18Day IBS 45 95 1-1-2000 - 12-26-12

We can see the equity curves of the cumulative IBS reinforces the conclusion in the cumulative DV2 post.

Here are the individual graphs in anyone is interested:

IBS 45 95 1-1-2000 - 12-26-12

2-day

Cum 2Day IBS 45 95 1-1-2000 - 12-26-12

3-day

Cum 3Day IBS 45 95 1-1-2000 - 12-26-12

4-day

Cum 4Day IBS 45 95 1-1-2000 - 12-26-12

5-day

Cum 5Day IBS 45 95 1-1-2000 - 12-26-12

6-day

Cum 6Day IBS 45 95 1-1-2000 - 12-26-12

7-day

Cum 7Day IBS 45 95 1-1-2000 - 12-26-12

8-day

Cum 8Day IBS 45 95 1-1-2000 - 12-26-12

9-day

Cum 9Day IBS 45 95 1-1-2000 - 12-26-12

10-day

Cum 10Day IBS 45 95 1-1-2000 - 12-26-12

11-day

Cum 11Day IBS 45 95 1-1-2000 - 12-26-12

12-day

Cum 12Day IBS 45 95 1-1-2000 - 12-26-12

13-day

Cum 13Day IBS 45 95 1-1-2000 - 12-26-12

14-day

Cum 14Day IBS 45 95 1-1-2000 - 12-26-12

15-day

Cum 15Day IBS 45 95 1-1-2000 - 12-26-12

16-day

Cum 16Day IBS 45 95 1-1-2000 - 12-26-12

17-day

Cum 17Day IBS 45 95 1-1-2000 - 12-26-12

18-day

Cum 18Day IBS 45 95 1-1-2000 - 12-26-12

Cumulative DV2 Indicator

Inspired by Larry Connors’ Cumulative RSI(2) (found in this post), I decided to test out how a Cumulative DV2 indicator would work. This is a frictionless test on SPY from 1/1/2000 – 12/26/2012. I tested the cumulative DV2 using default parameters (Buy/Cover if DV2 < 50 & Sell/Short if DV2 > 50)

Normal DV2:

DV2 50 1-1-2000 - 12-26-12

2-day cumulative DV2

Cum 2Day DV2 50 1-1-2000 - 12-26-12

3-day cumulative DV2

Cum 3Day DV2 50 1-1-2000 - 12-26-12

4-day cumulative DV2

Cum 4Day DV2 50 1-1-2000 - 12-26-12

5-day cumulative DV2

Cum 5Day DV2 50 1-1-2000 - 12-26-12

6-day cumulative DV2

Cum 6Day DV2 50 1-1-2000 - 12-26-12

7-day cumulative DV2

Cum 7Day DV2 50 1-1-2000 - 12-26-12

8-day cumulative DV2

Cum 8Day DV2 50 1-1-2000 - 12-26-12

9-day cumulative DV2

Cum 9Day DV2 50 1-1-2000 - 12-26-12

10-day cumulative DV2

Cum 10Day DV2 50 1-1-2000 - 12-26-12

11-day cumulative DV2

Cum 11Day DV2 50 1-1-2000 - 12-26-12

The results make me think of one of David Varadi‘s posts (link) about how mean-reversion isn’t necessarily ‘dead’, it has only changed to become mean-reverting on a longer period of time (per the equity charts of the 4-9 day cumulative DV2). An adaptive framework similar to that found at this post by Sanz Prophet could definitely be used.

XIV Donchian 50/25 Breakout Trading System

While surfing through the internet I found simulated VXX and XIV data going back to 2004. Here is the VXX data and here is the XIV data.

I’ve decided to trade a 50/25 Long-Only Donchian Breakout system on XIV, despite the fact that an Oscillator based system on VXX resulted in better risk/adjusted performance (long/short systems), simply because the brokerage I use does not have shares of VXX to short. The rules of the system are simple:

Buy: The close of today is higher than yesterday’s 50-day high of the close.

Sell: The close of today is lower than yesterday’s 25-day high of the close.

I use a 20% stop loss. This system was visually optimized, meaning I looked at the chart below while adjusting the parameters and chose parameters with round numbers that seemed to have the best risk/adjusted returns.

Visual Optimization

Here are the results of the system based off of the simulated data from above going back to 3/26/2004 and ending in 11/26/2012:

Result

I’ve allocated approximately 25% of my capital to this system. Friday afternoon (11/23/2012) a buy signal was generated. I bought 150 shares on the following Monday using a limit order, and managed to get filled at 18.65. I plan to follow this system until it experiences an 80% draw-down. In the future I will create a long only VXX system to use while this system is in cash.

There are two arguments against this system (or similar systems) that I’ve found:

1) 1987 style crashes will eat all the profits, and then some, that this system has generated. Found at Six Figure Investing’s post: “A Brief History of Fear.”

2) There is too little data to tell. The data dating back to 2004 only shows one current regime. According to user Damian Bergamaschi, a commenter on the post “Alpha Strategy” at Don’t Fear the Bear, “My findings show that the years 00-jan03 the market spent more days backwardated than in contango and 96-98 was almost the case as well.”

My refutations:

1) I can’t think of any reason not to be worried about this. I can only hope that my system will somehow exit before a crash of this magnitude. While the possibility of a crash of this magnitude happening within a day is slim, history has proven that it is still a possibility. If someone has an idea to safeguard against this, please share 🙂

2) I don’t think that a market with more contango than backwardation is only a regime. I think the markets have fully incorporated the fact that if there were as many days in backwardation as there is in contango, than investors could generate alpha relatively easily by using VIX-ETPs as a hedge. I could be wrong, but even if I am, the exit on a 25-day low should prevent the system from losing too much money in a backwardation environment.

Shorting Leverage

I came across the paper “Embedded Leverage” by Andrea Frazzini and Lasse Heje Pedersen. I didn’t have time to read it, but skimming over the abstract did spark some ideas from a previous paper I read. In the abstract, it states “we find that asset classes with embedded leverage offer low risk-adjusted returns and, in the cross-section, higher embedded leverage is  associated with lower returns. A portfolio which  is long low-embedded-leverage  securities and short high-embedded-leverage  securities  earns large abnormal returns, with t-statistics of  8.6 for equity options, 6.3 for index options, and 2.5 for ETFs.” This made me think of a previous paper I read, titled “Alpha Generation and Risk Smoothing using Volatility of Volatility” by Tony Cooper. In that paper, he talks about “Volatility Drag”, which is the deterioration of performance due to volatility, which can be seen by the following formula:

(1-x)(1+x) = 1-x^2

In leveraged ETFs, this volatility drag effect is amplified.

Thinking about both of those papers made me hypothesize that a portfolio consisting of shorting 3x leveraged ETFs could perform extremely well from two factors:

  1. The high “embedded leverage”
  2. The increased volatility drag

To test this hypothesis out, I backtested 3 systems shorting pairs of 3x leveraged ETFs. The pairs were chosen so that there was 1 inverse ETF and 1 regular, and that they were created by the same company. I chose inverse/non-inverse pairs so that the majority of the movements would cancel each other out and create a smoother equity curve, and I chose ETFs from the same company so that the pairs would have similar (but inverse) indexing methodologies. The positions were rebalanced daily using adjusted close prices from Yahoo! Finance. Commission and slippage were not accounted for. The ETF pairs are:

  • UPRO/SPXU
  • FAZ/FAS
  • GASL/GASX
  • RUSS/RUSL
  • TECL/TECS

There was no reason these particular ETFs were chosen. I just went to ETFdb.com and screened for 3x leveraged equity ETFs and ranked the ETFs by AUM. Then I chose a couple pairs.

FAS-FAZ Equity Curve

GASL-GASX Equity CurveRUSL-RUSS Equity Curve TECL-TECS Equity Curve SPXU-UPRO Equity Curve

While viewing these charts keep in mind that the testing period for some ETFs were longer than others, which will affect cumulative return.The returns for most of them are mediocre at best, but the equity curve is relatively stable. What worries me is the pair TECL/TECS. While such a drop has only occurred to 1/5 of these pairs, this kind of black swan event could ruin the strategy and is enough to warrant not implementing the strategy.

Next I will try to find evidence that the returns are derived increased volatility drag through by plotting the rolling 10-day return of the strategy with the rolling 10-day historical volatility of the strategy.

FAS-FAZ Volatility GASL-GASX Volatility RUSL-RUSS Volatility SPXU-UPRO Volatility TECL-TECS Volatility

From a cursory glance, volatility doesn’t seem to be a huge predictor of returns in any of the pairs except for FAS/FAZ.

Conclusion:

This strategy doesn’t generate enough alpha to warrant trading IMO. Even though it has a stable equity curve (depending on the securities traded) black swan events such as the one that occurred in TECS/TECL can devastate the already small profits. This combined with the fact that the system trades extremely frequently (once per day) and thus has relatively large commissions should counter-act any benefits the strategy has. Other than researching if the volatility of 1 of the ETFs is a predictor of  future returns, I’m not sure where else to continue researching/developing this strategy. If anyone has any thoughts/ideas please feel free to share 🙂

Side Note: This is the first time I’m using R. Everything should be calculated correctly, but I’m posting the code for this strategy so someone can point out an error in case I calculated something incorrectly.

# Function
getInvRet <- function(x) #Gets Inverse Daily Return
{
    raw.close <- read.csv(x) # read from CSV
    close <- raw.close[,7] # get Adjusted Close
    close <- rev(close) # flip the data
    ret <- close[-1]/close[-1*length(close)] # convert to daily ret
    inverse.ret <- -1*(ret-1) + 1 # inverse it for shorting
    inverse.ret
}
getPairRet <- function(retA, retB) #Calculates Shorting Rebalance Return
{
    equity <- retA * .5 + retB * .5
    equity <- c(1,equity)
    equity
}
movsd <- function(equity,lag) #Rolling Standard Deviation
{
    movingsd <- vector(mode="numeric",length(equity)-lag+1)
    for(i in lag:length(equity)) {movingsd[i-lag+1] <-sd(equity[(i-lag+1):i])}
    movingsd
}
movRet <- function(equity,lag) #Rolling Returns
{
    #for(i in 1:lag){}
    #for(i in length(equity)-lag+1:length(equity){}
    equity <- cumprod(equity)
    movingRet <- vector(mode="numeric",length(equity)-lag+1)
    for(i in lag:length(equity)) {movingRet[i-lag+1] <-equity[i]/equity[(i-lag+1)]} # this should be vectorized
    movingRet

}
#Get Inverse Returns
ret.fas <- getInvRet("fas.csv")
ret.faz <- getInvRet("faz.csv")
ret.gasl <- getInvRet("gasl.csv")
ret.gasx <- getInvRet("gasx.csv")
ret.rusl <- getInvRet("rusl.csv")
ret.russ <- getInvRet("russ.csv")
ret.spxu <- getInvRet("spxu.csv")
ret.upro <- getInvRet("upro.csv")
ret.tecl <- getInvRet("tecl.csv")
ret.tecs <- getInvRet("tecs.csv")

#Get Short Leverage Equity Curve
fas.faz <- getPairRet(ret.fas,ret.faz)
gasl.gasx <- getPairRet(ret.gasl,ret.gasx)
rusl.russ <- getPairRet(ret.rusl,ret.russ)
spxu.upro <- getPairRet(ret.spxu,ret.upro)
tecl.tecs <- getPairRet(ret.tecl,ret.tecs)

Mean-Reversion within Regimes

The standard “index” for mean-reversion strategies uses the following rules:

  • Buy/Cover = Close < Yesterday’s Close
  • Sell/Short = Close > Yesterday’s Close.

I will test this simple strategy within different regimes too see how regimes influence mean-reversion strategies as a whole. I will test this on SPY from 1/1/2000 – 7/30/2012 using Yahoo! Finance data. I chose these particular dates because mean-reversion as a whole performed poorly until the year 2000 and has performed relatively strongly for the majority of the testing period.

  • First, for the test of the simple trading rules above to establish a baseline to compare the future results to.
  • CAGR: 10.46%
  • MDD: 31.32%

For some reason, ever since 2009-ish this strategy has not performed as strongly. Below is the equity chart of this system.

MR Portfolio Equity

Bull/Bear:

To classify Bull and Bear Regimes I used the RSRank Indicator described by Jeff Swanson in this post at System Trader Success.

  • Bull: RSRank > 0
  • Bear: RSRank < 0

Results:

Bull:

  • CAGR: 0.07%
  • MDD: 38.74%

Bear:

  • CAGR: 10.40%
  • MDD: 27.58%

This clearly shows that MR seems to only perform well in Bearish conditions.

High/Low Volatility:

For determining High/Low Volatility regimes I will be using the 60-day standard deviation of daily returns.  The classifications for High-Volatility and Low-Volatility with the 60-day standard deviation of daily returns

  • HV: 60-Day Standard Deviation of Daily Returns > 0.01
  • LV: 60-Day Standard Deviation of Daily Returns < 0.01

Results:

HV:

  • CAGR: 9.25%
  • MDD: 36.21%

LV:

  • CAGR: 1.11%
  • MDD: 28.08%

This shows shows that MR performs well during high volatility environments.

Trending/MR:

The TSI is an indicator created by Frank Hassler from Engineering Returns and David Varadi from CSS Analytics. The formula can be found here. The classification for Trend Vs MR with the TSI():

  • Trending: TSI()>1.6
  • MR: TSI()<1.6

Results:

Trending:

  • CAGR: -1.86%
  • MDD: 34.24%

MR:

  • CAGR: 12.56%
  • MDD: 20.88%

It’s obvious that this strategy should work well during mean-reverting regimes, and that this strategy should perform poorly during trending periods. More than anything, the results of this particular test verify that TSI is a suitable indicator for determining mean-reverting and trend-following regimes.

Conclusion:

From this we should be able to see that mean-reversion trading strategies tend to work well when the regime is classified as mean-reverting by the TSI, when the market is bearish, and when the volatility is high.

DV2 Further Research

In this post I will test the DV2 with other indicators.

First I tested a simple DV2 system on SPY from 1/1/2000 – 7/30/2012 from Yahoo! Finance data. The rules were:

  • Buy/Cover: DV2 < 50
  • Sell/Short: DV2 > 50

The orders were taken at the day the signal was generated at the close price. The results were:

  • CAGR: 24.08
  • MDD: 42.67

All the tests after this use the same test dates, data source etc. as the test above.

DVI

The rules are:

  • Buy: DV2 < 50 & DVI < 50
  • Sell: DV2 > 50
  • Short: DV2 > 50 & DVI > 50
  • Cover: DV2 < 50

The results:

  • CAGR: 22.40%
  • MDD: 20.88%

These set of rules decrease the CAGR slightly yet decrease the MDD by over half.

A different variation of the rules:

  • Buy: DV2 < 50 & DVI < 50
  • Sell: DVI > 50
  • Short: DV2 > 50 & DVI > 50
  • Cover: DVI < 50

The results:

  • CAGR: 18.14%
  • MDD: 27.67%

Performance deteriorated versus the test above yet still beat the original on a risk/reward basis.

A different variation:

  • Buy/Cover: DV2 < 50 & DVI < 50
  • Sell/Short: DV2 > 50 & DVI > 50

The results:

  • CAGR: 15.73%
  • MDD: 27.67%

Performance deteriorated more.

A different variation:

  • Buy: DV2 < 50 & DVI < 50
  • Sell: DV2 > 50 | DVI > 50
  • Short: DV2 > 50 & DVI > 50
  • Cover: DV2 < 50 | DVI < 50

The results:

  • CAGR: 22.76%
  • MDD: 20.88%

A different variation:

  • Buy: DV2 < 50 | DVI < 50
  • Sell: DV2 > 50 | DVI > 50
  • Short: DV2 > 50 | DVI > 50
  • Cover: DV2 < 50 | DVI < 50

The results:

  • CAGR: 22.86%
  • MDD: 27.67%

A different variation:

  • Buy: DV2 < 50
  • Sell: DV2 > 50 | DVI > 50
  • Short: DV2 > 50
  • Cover: DV2 < 50 | DVI < 50

The results:

  • CAGR: 22.37%
  • MDD: 20.88%

IBS (or CRTDR)

I found this indicator with some background information at this QUSMA post. It seemed to be useful as an indicator on its own, and as a filter for other indicators. Just like in the QUSMA post, I use a 3-Day MA of the IBS.

The rules are:

  • Buy: DV2 < 50 & IBS < 50
  • Sell: DV2 > 50
  • Short: DV2 > 50 & IBS > 50
  • Cover: DV2 < 50

The results:

  • CAGR: 24.72%
  • MDD: 26.70%

A different variation of the rules:

  • Buy: DV2 < 50 & IBS < 50
  • Sell: IBS > 50
  • Short: DV2 > 50 & IBS > 50
  • Cover: IBS < 50

The results:

  • CAGR: 24.59%
  • MDD: 27.44%

A different variation:

  • Buy/Cover: DV2 < 50 & IBS < 50
  • Sell/Short: DV2 > 50 & IBS > 50

The results:

  • CAGR: 24.42%
  • MDD: 31.22%

A different variation:

  • Buy: DV2 < 50 & IBS < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50 & IBS > 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 25.38%
  • MDD: 19.79%

A different variation:

  • Buy: DV2 < 50 | IBS < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50 | IBS> 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 25.24%
  • MDD: 20.33%

A different variation:

  • Buy: DV2 < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 24.44%
  • MDD:  26.70%

RSI(2)

The rules are:

  • Buy: DV2 < 50 & RSI < 50
  • Sell: DV2 > 50
  • Short: DV2 > 50 & RSI > 50
  • Cover: DV2 < 50

The results:

  • CAGR: 21.92%
  • MDD: 35.00%

A different variation of the rules:

  • Buy: DV2 < 50 & IBS < 50
  • Sell: IBS > 50
  • Short: DV2 > 50 & IBS > 50
  • Cover: IBS < 50

The results:

  • CAGR: 19.28%
  • MDD: 28.34%

A different variation:

  • Buy/Cover: DV2 < 50 & IBS < 50
  • Sell/Short: DV2 > 50 & IBS > 50

The results:

  • CAGR: 20.48%
  • MDD: 33.70%

A different variation:

  • Buy: DV2 < 50 & IBS < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50 & IBS > 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 20.93%
  • MDD: 30.02%

A different variation:

  • Buy: DV2 < 50 | IBS < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50 | IBS> 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 23.02%
  • MDD: 30.13%

A different variation:

  • Buy: DV2 < 50
  • Sell: DV2 > 50 | IBS > 50
  • Short: DV2 > 50
  • Cover: DV2 < 50 | IBS < 50

The results:

  • CAGR: 21.88%
  • MDD:  35.01%

Conclusion:

While all the indicators improved the Risk/Reward versus the vanilla DV2 system, the best indicator seemed to be the IBS.

DV2 Indicator

I first learned of the DV2 Indicator in the paper: “MR Swing.”

Then I looked through the following research to see whether or not the indicator had been successfully applied.

And after, I found the indicator coded for AmiBroker at this Quanting Dutchman post.

I tested the basic system with SPY data from Yahoo! Finance from 1/1/2000 – 7/30/2012. The rules were:

  • Buy/Cover: DV2 < 50
  • Sell/Short: DV2 > 50

The results are below. I used the close price of the day the trading signal was generated.

Simple DV2 Spy Results

Simple DV2 Spy Equity Chart

The results of this indicator are quite good, especially for such a simple system.

Performance using a 3x Leveraged ETF:

Next, I decided to test the system on the 3x Leveraged ETF SSO , while still using the buy/sell signals from SPY.

The results are below. I used the close price of the day the trading signal was generated. The data from was from Yahoo! Finance from 6/22/2006 – 7 /30/2012.

SSO Results

SSO Equity Chart

The results of this system seem good from it’s CAGR, but upon closer inspection one can see that all of the returns are derived from 2007, 2008, and 2009 and that the returns these past years have been lackluster (similar to the performance on SPY, but the effect is magnified. The system could be failing as of late, or it could be that the system performs well under certain regimes.

Performance under Bull/Bear Regimes:

To classify Bull and Bear Regimes I used the RSRank Indicator described by Jeff Swanson in this post at System Trader Success.

  • Bull: RSRank > 0
  • Bear: RSRank < 0
Relative Strength Rank

Green = Bull Classification
Red = Bear Classification

Then I test going long only or short only (using the rules from above) in these regimes. Same conditions as the test above (data, dates, etc). The performance is:

  • Bull & Long: CAGR = 4.52% MDD = 20.44%
  • Bull & Short: CAGR = 2.61% MDD = 12.99%
  • Bear & Long: CAGR = 8.23% MDD = 20.88%
  • Bear & Short: CAGR = 7.05% MDD = 22.59%

Since there are not large discrepancies between the different regimes, it may not be wise to conclude that RSRank is a statistically significant method of classifying regimes or that bull/bear regimes do not affect the performance of the DV2.

Performance under Trending/MR Regimes:

  • TSI
  • ADX
  • R-Squared

TSI

The TSI is an indicator created by Frank Hassler from Engineering Returns and David Varadi from CSS Analytics. The formula can be found here. and The classification for Trend Vs MR with the TSI()

  • Trending: TSI()>1.6
  • MR: TSI()<1.6

To test, I used the same conditions as the test above (data, dates, etc).

  • Long & Short When Trending: CAGR = 2.45% MDD = 42.67%
  • Long & Short When MR: CAGR = 21.02% MDD = 20.88%

There can be an informal conclusion drawn from this (but not a formal one since this isn’t exactly the most rigorous test). The TSI can separate the market into regimes which the DV2 systems performs well/poorly. Whether or not this has anything to do with a MR or Trending environment is still questionable.

60-Day ADX

The classification for Trend Vs MR with the ADX

  • MR: ADX(60) > 10
  • Trending: ADX(60) < 10

I understand that traditionally, a higher ADX signifies a stronger trend, but for some reason when I looked at the chart of the ADX(60) it seemed that at high values, it signified a range-bound market, so I decided to use high values as a signal for a MR market. To test, I used the same conditions as the test above (data, dates, etc).

  • Long & Short When Trending: CAGR = 3.55% MDD = 39.13%
  • Long & Short When MR: CAGR = 19.82% MDD = 25.92%

This has results similar to that of the TSI() even though the times that it signifies as Trending of MR as that of the TSI.

60-Day R-Squared

The classification for Trend Vs MR with the R-Squared (as a function of the close and time)

  • Trending: R-Squared > 0.5
  • MR: R-Squared <0.5

Test results:

  • Long & Short When Trending: 9.86% MDD = 22.92%
  • Long & Short When MR: CAGR = 12.94% MDD = 31.73%

Breaking it down into regimes through R-Squared doesn’t seem to work effectively (there isn’t a significant different between the CAGR or MDD between MR and Trending states).

Performance under Volatility Regimes:

I will test performance of this basic system under the following measure of volatility:

  • 60-Day Standard Deviation of Daily Returns
  • 60-Day Standard Error (Normalized by dividing the standard error by that day’s closing price)

60-Day Standard Deviation of Daily Returns:

The classifications for High-Volatility and Low-Volatility with the 60-Day Standard Deviation of Daily Returns

  • HV: 60-Day Standard Deviation of Daily Returns > 0.01
  • LV: 60-Day Standard Deviation of Daily Returns < 0.01

To test, I used the same conditions as the test above (data, dates, etc).

  • Long & Short When HV: CAGR = 17.70% MDD = 26.14%
  • Long & Short When LV: CAGR = 5.42% MDD = 32.12%

The discrepancy between CAGR and MDD between these two regimes seem to be significant enough to warrant further analysis of volatility regimes.

60-Day Standard Error:

The classifications for High-Volatility and Low-Volatility with  the 60-Day Standard Error

  • HV: 60-Day Standard Error > 0.02
  • LV: 60-Day Standard Error < 0.02

To test, I used the same conditions as the test above (data, dates, etc).

  • Long & Short When HV: CAGR = 15.08% MDD = 25.92%
  • Long & Short When LV: CAGR = 7.81% MDD = 30.41%

Similar results as using the 60-Day Standard Deviation of the Daily Returns.