In last week’s article called, “Backtesting A Basic ETF Rotation System in Excel – Free Download“, Dan presented a simple rotational trading model which anyone could implement given a little knowledge in Excel. What I love about trading models like this is the simplicity. So often simplicity trumps complication. Simple systems often have one important characteristic. They often get you out of the market during bear markets and get you back in to ride the next bull cycle. That is, if you are disciplined enough to actually follow the rules, which of course is another entire topic.
Was the presented trading model perfect? Of course not. Looking at the equity curve it’s not very smooth. It’s personally not something I would trade. However, I hope the article gave you some ideas on what is possible with just using Excel.
At this point I would like to see if we can make some improvements in the trading model. Instead of using Excel I’m going to use the on-line backtesting service called ETFReplay. This web service allows you to create trading models and backtest them on a portfolio of ETFs. The website charges a monthly fee to use their service, but it’s very reasonable. It will be much quicker for me to test my changes using this service than using Excel. This is the same service I’ve used when creating the Ivy-10 portfolio.
First, I will recreate Dan’s original portfolio using ETFReplay to see if we get similar results. As a reminder, below is the original equity curve from the article. The trading model is the blue equity line.
Below are the results of the same model created in ETFReplay. The green equity line is our trading model while the blue line is the SPY (baseline).
As you can see the equity lines appear very similar. The ETFReplay version does end higher due to the fact my backtest ran through the entire year of 2014. This gives me confidence that the Excel model and the ETF model are identical in trading logic.
I will use the ETFReplay results as our baseline to compare our future results. To do this, we will need an in-sample data segment to test upon. Those dates will be through the year 2012. This gives us just over 100 trades for our in-sample data segment. Our baseline results are below.
When I look at the drawdown (31.4%) and view the equity curve of the original model, we can see it’s not very smooth. There are huge swings. Take a look at the huge peek in 2011 which falls dramatically. I would like to smooth it out. To do this, I’m going to use some ideas from the Ivy-10 rotational model.
First, instead of simply trading only the top ranked ETF I’m going to pick the top two. This will provide some diversification as our returns won’t be based on a single ETF. Next, I’m going to add a 5-month simple moving average (SMA) filter. This is the same filter length used in the Ivy-10. Adding this SMA filter will force the trading model to only buy an ETF when it’s experiencing a bull market. For our backtest the ETF SHY will be purchased if a top ranked ETF can’t be purchased because it’s below the SMA filter. SHY is Barclays Low Duration Treasury ETF. This will be our cash equivalent.
In summary, we are changing these two settings:
This produces an increase of about 1% in the annual return but does nothing to change the max drawdown.
Let’s now apply our new model to our out-of-sample results. The out-of-sample results will conclude on December 31, 2014.
It appears we are making new equity highs. For the years 2013 and 2014 the trading model returned annual returns of 12.9% and 4.4% respectively. We can see our final CAGR is 15.9% and our max drawdown remains at 17.6%.
With a few minor modifications it appears we can improve this trading model to the point where it actually might be tradable with real money. At this point I don’t feel there are enough trades in the out-of-sample segment. Note our in-sample results consisted of 170 and our out-of-sample run had a total of 202 trades. This means we only have about 32 trades in the out-of-sample data segment. It would be nice to have some more trades logged and that means we sit tight and watch this model for at least another year.
Jeff is the founder of System Trader Success - a website and mission to empowering the retail trader with the proper knowledge and tools to become a profitable trader the world of quantitative/automated trading.
Please log in again. The login page will open in a new tab. After logging in you can close it and return to this page.