Technical Trading
Does technical trading work, or not? Rationalists dismiss it; behavioralists investigate it. Is there any verdict? These blog entries relate to technical trading.
August 25, 2021 - Economic Indicators, Technical Trading
A subscriber asked about a stock market timing strategy that combines the market 10-month simple moving average (SMA10) and the Sahm Recession Indicator (Sahm), which signals the start of a recession when the 3-month SMA of the U.S. unemployment rate is at least 0.5% higher than its low during the last 12 months. Specifically, the strategy:
- Holds the S&P 500 Index (SP500) unless it is below its SMA10 and Sahm first signals a recession.
- Subsequently holds cash until SP500 crosses above its SMA10.
To investigate, we compare three alternative strategies:
- SP500 – buy and hold the index.
- SMA10 – hold the index only while it is above its SMA10 and otherwise hold cash.
- SMA10+Sahm – combined signals as specified above.
We focus on average monthly return, standard deviation of monthly returns, monthly reward/risk (average return divided by standard deviation), compound annual growth rate (CAGR) and maximum drawdown (MaxDD) as key performance metrics. Using end-of-month levels of SP500 since March 1959, Shiller’s monthly SP500 dividends (to estimate SP500 total returns) since January 1960, Sahm since inception in December 1959 (history vintage 8/6/2021) and T-bill yield since December 1959, all through July 2021, we find that:
Keep Reading
August 23, 2021 - Calendar Effects, Technical Trading
A subscriber requested review of a swing trade strategy that buys and sells Invesco QQQ Trust (QQQ) according to the following rules:
- Buy at the close when it is either Monday or Tuesday and QQQ (Close-Low)/(High-Low) is 0.15 or less.
- Subsequently sell at the close when it is higher than the prior-day high.
To investigate, to simplify portfolio cash management, we assume that there are no overlapping trades (if a position opens on Monday, another position does not open on Tuesday). We further assume that cash earns the 3-month U.S. Treasury bills (T-bill) yield when not in QQQ and that frictions for switching between T-bills and QQQ are 0.10% of trade value. Using daily high, low, close and dividend-adjusted close (to calculate returns) for QQQ and daily T-bill close during March 10, 1999 (QQQ inception) through August 5, 2021, we find that:
July 8, 2021 - Economic Indicators, Fundamental Valuation, Investing Expertise, Technical Trading
Can machine learning-generated stock market crash predictions be amenable to human interpretation? In their June 2021 paper entitled “Explainable AI (XAI) Models Applied to Planning in Financial Markets”, Eric Benhamou, Jean-Jacques Ohana, David Saltiel and Beatrice Guez apply a gradient boosting decision tree (GBDT) to 150 technical, fundamental and macroeconomic inputs to generate daily predictions of short-term S&P 500 Index crashes. They define a crash as a 15-day S&P 500 Index return below its historical fifth percentile within the training dataset. The 150 model inputs encompass:
- Risk aversion metrics such as asset class implied volatilities and credit spreads.
- Price indicators such as returns, major stock index Sharpe ratios, distance from a long-term moving average and and equity-bond correlations.
- Financial metrics such as 12-month sales growth and price-to-earnings ratio forecasts.
- Macroeconomic indicators such Citigroup regional and global economic surprise indexes.
- Technical indicators such as market breath and index put-call ratio.
- Interest rates such as 10-year and 2-year U.S. Treasury yields and break-even inflation level.
They first rank and filter the 150 inputs based on GBDT to discard about two thirds of the variables. They then apply the Shapley value solution concept to identify the most important of the remaining variables and thereby support interpretation of methodology outputs. Using daily values of the 150 model inputs and daily S&P 500 Index roll-adjusted futures prices from the beginning of January 2003 through mid-January 2021 (with data up to January 2019 used for training, the next year for validation and the rest for testing), they find that:
Keep Reading
May 21, 2021 - Technical Trading
Does the recency effect evident for U.S. stock returns carry over to stocks globally? In their May 2021 paper entitled “Chronological Return Ordering and the Cross-Section of International Stock Returns”, Nusret Cakici and Adam Zaremba examine whether the recency effects holds among stocks worldwide. Their measure of recency (Chronological Return Ordering, CRO) for each stock each month is the correlation between daily returns and number of days until the end of the month. Low (high) CRO values indicate relatively high (low) recent returns and relatively low (high) older returns. Low (high) CRO values imply low (high) future returns. To measure the recency effect, they each month sort stocks into tenths, or deciles, and reform an equal-weighted or value-weighted hedge portfolio that is long (short) the decile with highest (lowest) recency correlations. Using daily and monthly returns and other data for stocks from 49 countries (23 developed markets and 26 emerging ones) as available starting January 1990 through December 2020 (a total of 92,680 stocks, 62,495 from developed markets and 30,185 from emerging markets), they find that: Keep Reading
May 20, 2021 - Technical Trading
Do naive investors overvalue (undervalue) stocks with relatively high (low) recent returns, thereby causing exploitable overpricing (underpricing)? In the April 2019 version of his paper entitled “The Impact of Recency Effects on Stock Market Prices”, Hannes Mohrschladt devises and tests a measure of this recency effect based on correlation between daily returns during a month and the number of days until the end of the month. For stocks with low (high) values of this correlation:
- Recent returns are relatively high (low) and older returns are relatively low (high).
- Naive investors overvalue (undervalue) such stocks, which therefore become overpriced (underpriced).
- There is an opportunity to exploit this effect by buying (selling) stocks with high (low) values of this variable.
His principal test is to each month sort stocks into tenths, or deciles, by prior-month recency correlation and reform an equal-weighted or value-weighted hedge portfolio that is long (short) the decile with high (low) recency correlations. He also considers a 1-year lookback interval using monthly returns rather than a 1-month interval using daily returns for calculation of recency correlations. Using daily and monthly returns and other data for a broad sample of U.S. common stocks during January 1926 through December 2016, he finds that: Keep Reading
May 12, 2021 - Technical Trading
Is buy-the-dip (BTD) a reliably attractive stock market timing approach? In their April 2021 paper entitled “Buy the Dip”, Thomas Shohfi and Majeed Simaan devise and test various BTD strategies as applied to SPDR S&P 500 ETF Trust (SPY), as follows:
- BTD with Lump Sum – 54 variations in which the investor progressively allocates a fixed percentage of an initial lump sum to SPY whenever the last real monthly return on SPY is below a specified threshold. Variations derive from different fixed allocation percentages and different return thresholds.
- BTD with Monthly Inflows – five variations in which the investor receives cash flows at the beginning of each month and moves one monthly increment from cash to SPY whenever its prior-day return is below a specified threshold. Variations derive from different return thresholds.
- BTD with MaxDD – nine variations in which the investor receives cash flows at the beginning of each month and initiates the strategy with 12 months of savings, allocating all cash savings to SPY whenever SPY drops below a maximum drawdown (MaxDD) threshold over a past rolling window. Variations derive from different MaxDD thresholds and different rolling window lengths.
They consider four strategy implementation dates, two associated beginnings of bull markets (January 1994 and January 2010) and two associated with beginnings of bear markets (January 2000 and January 2008). They use real (inflation-adjusted) returns on SPY and also deflate value of cash holdings accordingly. They focus on two strategy performance criteria: (1) terminal wealth at the end of 2020; and, (2) Sortino ratio. Respective benchmarks are passive strategies that allocate all cash to SPY as soon as the cash is available. They assume zero trading frictions and zero return on cash. Using daily dividend-adjusted SPY returns and monthly U.S. Consumer Price Index levels for inflation adjustments during January 1994 through December 2020, they find that: Keep Reading
January 21, 2021 - Technical Trading
Can machine learning software discover predictive stock price patterns? In their December 2020 paper entitled “(Re-)Imag(in)ing Price Trends”, Jingwen Jiang, Bryan Kelly and Dacheng Xiu apply convolutional neural network machine learning software to analyze stock price series images (depicting daily open, high, low, close and moving average prices and trading volume) in search of the patterns most predictive of future returns. Their model standardizes price series scales, recursively smooths and accentuates certain shape elements of images of the last 5, 20 and 60 days trading to isolate patterns that predict returns over the next 5, 20 and 60 days. They translate predictions into hedge portfolio performance by each month going long (short) the tenth, or decile, of stocks with the strongest (weakest) return forecasts. They benchmark performance against hedge portfolios for conventional momentum (return from 12 months ago to one month ago), 1-month short-term reversal and 1-week short-term reversal. Using daily price and volume series for all listed U.S. stocks during January 1993 through December 2019, they find that: Keep Reading
December 16, 2020 - Bonds, Equity Premium, Gold, Technical Trading
A subscriber asked about a strategy that switches between an equal-weighted portfolio of Invesco QQQ Trust (QQQ) and iShares Russell 2000 ETF (IWM) when the S&P 500 Index is above its 200-day simple moving average (SMA200) and an equal-weighted portfolio of SPDR Gold Shares (GLD) and iShares 20+ Year Treasury Bond ETF (TLT) when below. Also, more generally, is an equal-weighted portfolio of GLD and TLT (GLD:TLT) superior to TLT only for risk-off conditions? To investigate, we (1) backtest the switching strategy and (2) compare performances of GLD:TLT versus TLT when the S&P 500 Index is below its SMA200. We consider both gross and net performance, with the latter accounting for 0.1% portfolio switching frictions 0.001% daily portfolio rebalancing frictions (rebalancing one hundredth of portfolio value). As benchmarks, we consider buying and holding SPDR S&P 500 ETF Trust (SPY) and a strategy that holds SPY (TLT) when the S&P 500 Index is above (below) its SMA200. Using daily S&P 500 Index levels starting February 5, 2004 and daily dividend-adjusted levels of QQQ, IWM, GLD, TLT and SPY starting November 18, 2004 (limited by inception of GLD), all through November 25, 2020, we find that:
Keep Reading
November 10, 2020 - Economic Indicators, Political Indicators, Sentiment Indicators, Technical Trading
A subscriber requested, as in “Combine Market Trend and Economic Trend Signals?”, testing of a strategy that combines: (1) U.S. Economic Policy Uncertainty (EPU) Index, as described and tested separately in “Economic Policy Uncertainty and the Stock Market”; and, (2) U.S. stock market trend. We consider two such combinations. The first combines:
- 10-month simple moving average (SMA10) for the broad U.S. stock market as proxied by the S&P 500 Index. The trend is bullish (bearish) when the index is above (below) its SMA10 at the end of last month.
- Sign of the change in EPU Index last month. A positive (negative) sign is bearish (bullish).
The second combines:
- SMA10 for the S&P 500 Index as above.
- 12-month simple moving average (SMA12) for the EPU Index. The trend is bullish (bearish) when the EPU Index is below (above) its SMA12 at the end of last month.
We consider alternative timing strategies that hold SPDR S&P 500 (SPY) when: the S&P 500 Index SMA10 is bullish; the EPU Index indicator is bullish; either indicator for a combination is bullish; or, both indicators for a combination are bullish. When not in SPY, we use the 3-month U.S. Treasury bill (T-bill) yield as the return on cash, with 0.1% switching frictions. We assume all indicators for a given month can be accurately estimated for signal execution at the market close the same month. We compute average net monthly return, standard deviation of monthly returns, net monthly Sharpe ratio (with monthly T-bill yield as the risk-free rate), net compound annual growth rate (CAGR) and maximum drawdown (MaxDD) as key strategy performance metrics. We calculate the number of switches for each scenario to indicate sensitivities to switching frictions and taxes. Using monthly values for the EPU Index, the S&P 500 Index, SPY and T-bill yield during January 1993 (inception of SPY) through September 2020, we find that:
Keep Reading
November 4, 2020 - Technical Trading
A subscriber requested testing of a dual simple moving average (SMA) crossover strategy that holds SPDR S&P 500 (SPY) when its 30-day SMA (SMA30d, using 30 trading days) is above its 9-month SMA (SMA9m) and otherwise holds cash with yield that of 3-month U.S. Treasury bills (T-bills). To investigate, we calculate SPY SMA30d and SMA9m at the end of each month over the history of SPY and hold SPY or cash the next month as specified. As benchmarks, we consider buying and holding SPY and a strategy that is each month in SPY (cash) when SPY is above (below) its SMA9m at the end of the prior month. We focus on compound annual growth rate (CAGR) and maximum drawdown (MaxDD) as key performance metrics. We also perform some sensitivity testing on the choices of 30-day and 9-month SMAs. Using daily dividend-adjusted prices for SPY and monthly T-bill yields during January 1993 through September 2020, we find that: Keep Reading