I've taken a bit of a break from posting options strategy research, but before I dive back in I'm going to revisit some material I posted on Momentum Rotation systems last year.
If you're new to my blog you may have missed my posts related to rotation system results and data. For the last several years, I have been trading monthly Momentum Rotation strategies across six accounts. These strategies rank portfolios containing between 10 and 30 ETFs or mutual funds by momentum. Some of my strategies combine multiple momentum readings to derive a rank, while others go further and add filters. All of my rotation strategies rank a basket of funds relative to each other...and this is a common approach across all Momentum Rotation systems, not just mine.
I use AmiBroker and Yahoo! end-of-data data (Yahoo Data Info 1, Yahoo Data Info 2) for my rotation strategies. A few years ago I began to realize that the signals I was receiving (and trading on!) from my rotation strategies were occasionally inconsistent with the backtests of these same strategies. I didn't spend much time digging into the issue at the time, but it remained in the back of my mind.
In August 2014, I decided to backtest my live rotation strategies across the same period that I had actively traded with these same rotation strategies. I found that a number of the trades in the backtests did not match the trades I had actually executed and recorded in my spreadsheets.
I initially thought the issue was caused by using dividend adjusted data rather than actual data, but in my last Momentum Rotation post (here) I realized this was not the issue. Dividend adjusted data does result in stable Momentum Rotation rankings as dividends are issued. I also analyzed several ETFs to determine if their ROC values were stable across dividend issuance, and they were.
Based on these findings and some advice from Cesar Alvarez, I started taking taking snapshots of my AmiBroker database at the end of each month beginning in March of 2015. I continued taking database snapshots through January of 2016...11 months in total. Planning to get to the bottom of the mismatch between the actual signals and the backtest signals, I ran backtests of my live systems across each database snapshot and compared these signals with the signals I actually traded. Surprisingly, there was no difference ... the backtest signals from all 11 database snapshots matched my live signals during those same periods.
What changed during those 11 months compared to the time prior to March of 2015? Well, I had made one small change...so I thought! Prior to March, 2015 I did not perform complete historical data updates very often...and I would typically only update the last several months of historical data when I did perform an update...and this was a big mistake that I did not recognize!
Beginning in March, 2015 I started performing complete database updates on the 25th of each month. With these updates, I re-downloaded all of my historical data from January 1st, 1900 to the present. This corrected my signal instability problem. The lack of complete historical updates had been a big mistake on my part and resulted in my backtest signals not matching the signals I had actually traded.
The big take away ... if you're not already doing this ... perform a complete historical data update prior to generating your live trading signals. If your data is dividend and split adjusted, you need to update the entire series...pretty obvious now, but something I missed...hopefully others will learn from my mistake!
In my next post, I will review the 2015 results of the Momentum Rotation system that I shared in March 2015 (here).
Lastly, I just started reading Momo Traders (full disclosure, Brady Dahl sent me a copy) and it reminds me of the Market Wizards series. I'm only on the first interview, so no book review yet, but I am enjoying it so far.
Follow my blog by email, RSS feed or Twitter (@DTRTrading). All options are available on the top of the right hand navigation column under the headings "Subscribe To RSS Feed", "Follow By Email", and "Twitter".
A blog about options trading strategies (Iron Condors, Strangles, Calendars, Butterflies), equities rotation strategies, and Java related technologies to backtest and automate trading.
1 comment:
This is actually a very common issue in the financial services industry dedicated to calculating accurate returns on securities, ETFs, mutual funds, etc. The issue is indeed that Yahoo provides data adjusted for dividends. This ensures that if someone takes a price for the current day and attempts a simple return calculation by comparing it to a price from a year ago, they will generate a return that represents what someone would expect if they owned that ETF or security. The return of a security is made up of both the change in price plus any dividends paid out to the investor. I think Yahoo adjusts the historical data so that the current market price in their data matches their data. It also likely invites the least amount of questions from the public.
Another way to calculate the performance is to start with an original price of the security and adjust the current price based on dividends or other adjustments. This is similar to what is done for total return indices. The indices usually reported in the financial media is the price return index. If you are trying to calculate performance, you should use a total return index. Total return indices are what are generally used by people in the industry such as portfolio managers, pension plan administrators, endowment funds, etc.
If you want to maintain "pure" security prices so that you could look at the price of a security now and it matches the published price of the security from a year ago, then you need to abandon the idea of using a simple return calculation by comparing the two prices. You then need a process to account for the dividend declaration, which we usually do by recording the amount of the dividend as an outflow. Because the price of a security will generally go down by the amount of the dividend when the dividend when it is declared, recording the dividend as an outflow ensures we do not understand the performance of the security or fund.
Let me know if you have any questions or want to trade ideas on calculating performance. I haven't had any experience building trading systems but I have had a lot of experience building return calculation performance systems and dealing with the data to ensure it is used appropriately.
Post a Comment