Showing posts with label moving average. Show all posts
Showing posts with label moving average. Show all posts

Thursday, October 31, 2024

How to beat the S&P 500 without much effort: A one-year moving average strategy


Summary

- One of the most successful strategies for long-term investment returns is to buy and hold a broad-coverage index fund.

- The SPY is an exchange-traded fund (ETF) that tracks the S&P 500, and is a good example of broad-coverage index fund.

- A simple strategy can be devised to obtain even better than buy-and-hold long-term returns, employing fast- and slow-moving averages.

- We explain and test a one-year moving average strategy that in the long term performs significantly better than buying and holding SPY.

The one-year moving average for SPY from 1995 to 2018

The graph below has been created with Yahoo Finance (). It shows the variation of the SPY exchange-traded fund (ETF) from 1995 to 2018 (in red), plus the one-year moving average during that period (in blue). The SPY tracks the S&P 500 index, and had a net expense ratio of 0.09% at the time of this writing. One of the advantages of index funds is that they have a low expense ratio compared with actively-managed mutual funds.



Note that there are two moving averages in the graph: (a) the SPY “share” price (or net asset value per share) at any given time, which is the fastest moving average possible for the fund; and (b) the SPY’s one-year moving average, which is a slow-moving simple average of the fund’s share prices. (see ).

Simple inspection would suggest that, after an initial purchase, one would do better than holding SPY by employing a simple two-step strategy: (1) sell when the SPY crosses below its one-year moving average; and (2) buy back when SPY crosses above its one-year moving average.

A test of the strategy

While on the graph the simple strategy above may look appealing, the strategy must be tested with real data and under realistic assumptions. The figure below shows part of a screen snapshot of a test of the strategy, with multiple trades on a spreadsheet. Each row of the spreadsheet corresponds to one trade. The first row corresponds to the initial buy. A conservative fee of US$ 40 per trade is assumed, in part to account for bid-ask spread losses.




The figure below shows the final rows of the simulation, the result of a comparison buy-and-hold baseline strategy, and the percentage difference. Starting with an investment of US$ 100,000 made in January 1, 1995, the simple one-year moving average strategy gets us to US$ $980,558 on January 1, 2018. The buy-and-hold baseline strategy gets us to US $611,714. That is, the simple one-year moving average strategy performs about 60 percent better.




The simulation disregards dividends and sweep account gains (whereby cash earns interest). At the time of this writing, one could easily get money market yields in sweep accounts that were comparable in value to the SPY dividend.

Is the 365 days used for the moving average optimal? Probably not, but our simulation suggests that this number is effective at limiting false positives while at the same time capturing major drops of the index (e.g., those in the two recessions in the period considered). False positives would be much more frequent with a faster moving average, such as a 50-day moving average. If too frequent, false positives can significantly increase trading-related losses, to the point of negating the benefit of the strategy.

Sunday, November 4, 2018

Next S&P 500 bottom? Maybe 1468


Summary

- The S&P 500 index (SP500) has been recently dropping.

- The Shiller (PE10) has also been dropping.

- We can estimate the bottom of the SP500 based on historical PE10 values.

- This estimated SP500 bottom is 1468.94.

Faster moving averages chase slower ones

The picture below shows two charts prepared with Yahoo Finance (). The top chart shows the SP500 together with its 5-month moving average. The bottom chart also includes the 10-month moving average.



This picture illustrates one import point: faster moving averages usually “chase” slower ones. This is, of course, a figure of speech.

The fastest moving average of all is the index itself; e.g., the 1-month moving average of the index measured on a 1-month basis.

The corresponding 5-month moving average is slower, and the 10-month is even slower.

The slowest moving average of all is the average (or mean) of the index over its entire history.

History tells us that, as the gap between the fastest and slowest moving averages increases, so does the likelihood that they will converge with a “vengeance” – at a wide angle.

The Shiller PE ratio

The Shiller PE ratio (PE10) () is based on average inflation-adjusted earnings from the previous 10 years. As such it removes the “contamination” of inflation and other factors that artificially influence the denominator of the standard PE ratio. This is why we use it here.

In October 2018 the PE10 reached 33.01, the second highest peak in its history. Since then it has been going down, presumably chasing a moving average. If it were to bottom, history suggests that it would go down to around the slowest moving average: its historical average of 16.58 (approximately, in October 2018).

The SP500 bottom

The PE10 going from 33.01 to 16.58 would be a drop of 49.77 percent.

The SP500 was 2924.59 in October 2018. A drop of 49.77 percent would take it to 1468.94.