Home » Research Blog » FX trend following and macro headwinds

FX trend following and macro headwinds

Jupyter Notebook

Trend following can benefit from consideration of macro trends. One reason is that macroeconomic data indicate headwinds (or tailwinds) for the continuation of market price trends. This is particularly obvious in the foreign-exchange space. For example, the positive return trend of a currency is less likely to be sustained if concurrent economic data signal a deterioration in the competitiveness of the local economy. Macro indicators of such setback risk can slip through the net of statistical detection of return predictors because their effects compete with dominant trends and are often non-linear and concentrated. As a simple example, empirical evidence shows that standard global FX trend following would have benefited significantly merely from adjusting for changes in external balances.

The below post is based on proprietary research of Macrosynergy.

A Jupyter notebook for audit and replication of the research results can be downloaded here. The notebook operation requires access to J.P. Morgan DataQuery to download data from JPMaQS, a premium service of quantamental indicators. J.P. Morgan offers free trials for institutional clients.

Also, there is an academic research support program that sponsors data sets for relevant projects.

This post ties in with this site’s summary of the importance of macro trends.

The headwind theory

In algorithmic trading, a trend is defined as a sustained general direction of prices in the market such that today’s measurable trend statistic predicts tomorrow’s return. Popular statistics of this type are moving average differences, relative strength indices, and average directional indices. Trend-following is an investment strategy that exploits this predictive power of past price trends. Empirical evidence and the large amount of assets managed under such strategies bear witness to the attraction of the approach. Commonly quoted causes for the predictive power of trends include gradual dissemination of information, herding (view post here), lazy trading (view post here), and behavioral biases, such as the disposition effect (view post here).

Simple price trend-following plausibly benefits from the consideration of macro information. Macro information here mainly refers to time series that directly report on states of the broader economy that are plausibly relevant for market prices, such as inflation, growth, or changes to external balances. A previous post on this subject (view post here) showed that market and macro trends have complementary strengths as trading signals. Price trends are timely but not very precise concerning their information content. Macro trends are lagging behind the actual economic activity but are very specific regarding the information they convey. Empirical evidence shows that combined consideration of both leads to more profitable trading strategies.

In this post, we focus on a second strong argument for considering macro trends: when price trends have gone too far, they are often undermined by their macroeconomic consequences. Examples of such economic headwinds can be found in all asset classes but seem particularly obvious in the FX space. Excessive currency appreciation or depreciation relative to fundamental developments leaves its mark on the performance of external balances, growth, inflation, etc. For example, steep currency appreciation of an open economy may result in lower growth, subdued inflation, or widening external deficits. Evidence of such effects will affect monetary policy and business decisions and work against the persistence of price trends.

Why standard statistical criteria miss macro headwinds

The evaluation of trading signals often relies on correlating them with future returns on a daily, weekly, or monthly basis or assessing their accuracy in predicting the direction of returns. However, macro headwinds may not always perform well according to these metrics for two main reasons:

  • Sporadic non-linear effects: Many headwind factors indicate a growing risk of a setback to the general market direction. For example, currency appreciation may lead to a widening external current account deficit in an overheating economy. However, deteriorating macro indicators may only raise concern when they exceed a certain threshold or when other conditions, such as global funding pressure, come into play. This means that macro warning signs may occasionally cause abrupt setbacks. These types of headwinds do not exhibit regular linear co-movements and do not much affect accuracy statistics.
  • Risk premium effects: Several macro headwinds, such as external or fiscal deficits, carry a risk premium. As long as this macro risk does not materialize, the relationship between the headwind and returns may be positive rather than negative. In general, if a macro headwind acts as a natural counterweight to an excess in the market, it may initially not display predictive power on its own. Backward-looking statistics with limited historical data may struggle to detect their significance right until it finally sways the mood in the market and displays their importance.

This makes macro headwinds prone to slipping past the net of machine learning selections. However, they are naturally beneficial when used in conjunction with a trend signal, as they improve information on trend sustainability and reduce the risk of continued long-term failure in a fundamentally mean-reverting environment.

A simple example

We tested if the consideration of external balances benefits a simple trend-following strategy for developed and emerging markets FX forwards from 2002 to April 2023. The panel thus encompasses the era of broad exchange rate flexibility and convertibility in the EM space and features 27 currencies. It excludes some intermittent periods for currencies whose flexibility, liquidity, or convertibility were restricted.

In particular, we consider trading all liquid 1-month FX forwards or non-deliverable forward contracts in countries with largely convertible currencies and flexible exchange rates. By this criterion, we selected the following currencies: AUD, BRL, CAD, CHF, CLP, COP, CZK, GBP, HUF, IDR, ILS, INR, JPY, KRW, MXN, MYR, NOK, NZD, PEN, PHP, PLN, RON, SEK, THB, TRY, TWD, and ZAR. For an explanation of the currency, see the annex at the bottom of the post.

FX forwards are traded against their “natural benchmark currencies,” the USD for most countries, except for European currencies, which trade mainly against EUR or against both (GBP and TRY). As base currencies, the USD and EUR are not considered as separate trades. For the purpose of all analyses, positions are volatility targeted to equalize the exposure per unit signal across markets.

We calculate trend measures for all 27 FX forward markets simply as the normalized differences between 50-day and 200-day moving averages of return indices. This is in no way optimized but merely the most frequently quoted default standard for trends.

As complementary macro headwind (or tailwind) statistics, we consider quantamental metrics of external balance changes. Of course, this is just one possible macro headwind. For a fully-fledged strategy, one would consider a broader macro picture, including relative growth, inflation, or financial conditions. However, a single macro indicator is enough to illustrate the principal case for adjustment.

For a meaningful analysis of the impact of economic trends on market returns, we use indicators of the J.P. Morgan Macrosynergy Quantamental System (“JPMaQS”). Quantamental indicators are real-time information states of the market and the public with respect to an economic concept and, hence, are suitable for testing relations with subsequent returns and backtesting related trading strategies.

As representations of medium-term changes in external balances, we use the following:

  • Basic external balance (current account plus net FDI trend), as % of GDP: 1-year average versus 5-year average.
  • Merchandise trade balance, seasonally adjusted, as % of nominal GDP latest 3 months versus 5-year average.
  • Merchandise trade balance, seasonally adjusted, as % of nominal GDP latest 3 months versus 10-year average.

As representations of short-term changes in external balances, we chose the following:

  • Basic external balance as % of nominal GDP, 1-year moving average. change over last three reported months.
  • Merchandise trade balance as % of nominal GDP, 1-year moving average, change over last three reported months.
  • Merchandise trade balance as % of nominal GDP, 3-month moving average over previous 3 months.
  • Merchandise trade balance as % of nominal GDP, 6-month moving average over previous 6 months.

The choice of indicators has been based on plausibility and convention. It has not been optimized in any way. All constituents are z-scored and then averaged to give effectively equal weights to all constituents (except for the two short-term trade balance changes, which are highly correlated and count as one). We call the composite z-score “external balance dynamics scores.” The below panel shows these scores for all currency areas. They are naturally stationary, but positive and negative periods can last over several years, and variance has differed notably across countries.

We first consider the predictive power and economic value of (a) the standard trend and (b) the external balance dynamics scores separately. The trend signal posts a more significant forward correlation at a monthly frequency (99.5% probability) and higher balanced accuracy (52.2%) than the external balances dynamics score (65% and 50.8%, respectively).

However, a naïve PnL check paints a different picture. We calculate naïve PnLs based on standard rules, like the ones used in previous posts. Positions are taken based on trend or external balance dynamics scores in units of vol-targeted positions. The z-scores are winsorized at two standard deviations to reduce the impact of data outliers. Positions are rebalanced monthly with a one-day slippage added for trading. The long-term volatility of the PnL for positions across all currency areas has been set to 10% annualized.

These naïve PnLs suggest that the economic value of the external dynamics score (Sharpe 0.43) has been greater than that of the trend score (Sharpe 0.21). More importantly, the two have been highly complementary. While the trend signal produced all its value in the 2000s, the external dynamics score produced consistent positive returns from 2008 to 2022.

Similar to a previous post on carry adjustment (view post here), we then consider two types of trend adjustment. Modification reduces and enhances the trend but does not override it by changing its sign. Balancing adds macro quantamental information to the trend signal, giving them pre-assigned (here equal) weights.

The trend modification here is achieved by multiplying the original trend signal with a coefficient that can take values between 0 and 2, i.e., can reduce or double the original trend signal. The modification coefficient is a logistic (sigmoid) function of the external strength z-score. Specifically, the adjustment implements the following equation:

modified_trend = ((1 - sign(trend)) + sign(trend) * coef) * trend

for

coef = 2/(1 + exp(-2 * xscore))

where trend means the original trend, sign() returns the sign of its element as 1/-1, and xscore denotes the external dynamics score.

The application depends on the sign of the concurrent trend signal: if the trend signal is positive external strength enhances it, and external weakness reduces it. The logistic function translates the external balances dynamics score such that for a value of zero, it is 1. For values of -1 and 1, it is 0.25 and 1.75, respectively, and for its minimum and maximum of -3 and 3, it is 0 and 2, respectively.

Empirically, the modification slightly increases monthly correlation with subsequent FX forward returns but naturally does not affect the accuracy statistics. Meanwhile, the economic benefit is notable, if only since 2012. The naïve PnL comparison shows that modification prevented most of the losses that trend following incurred in the 2010s, lifting the long-term Sharpe to 0.32 from 0.2.

The alternative to a modified trend is a balanced trend. Here we simply average the trend z-score and the external balance dynamics z-score. The effect of doing so would have been similar to trend modification, albeit a little more pronounced. Interestingly, balancing the trend signal would have reduced monthly accuracy and balanced accuracy of return predictions relative to simple trend following but significantly increased economic trading value.

Macro balancing has been essential for trend-following in emerging market currencies. This is plausible since external deficits more often contribute to disruptions of capital flows in the EM space. Simple trend following hardly produced any value over the last 20 years in directional EM trading, while balanced trend following at least held on to its boom-time gains during the 2010s and early 2020s.

A balanced trend following strategy would have produced higher naïve PnL value with less seasonality when applied to relative FX forward positions, i.e., trends and returns of any of 27 currencies versus a basket of all currencies. A balanced trend score would have delivered a Sharpe ratio of roughly 0.37. True, the simple trend score would have delivered roughly similar returns but with much greater seasonality.

Again, the importance of external balance adjustment has turned out to be greater for the EM space, where a balanced trend score would have produced a long-term naïve Sharpe ratio of 0.48 and more consistent value generation than a simple trend score.

Annex: Currency symbols

In alphabetical order, the currency symbols and their meanings are AUD (Australian dollar), BRL (Brazilian real), CAD (Canadian dollar), CHF (Swiss franc), CLP (Chilean peso), COP (Colombian peso), CZK (Czech Republic koruna), GBP (British pound), HUF (Hungarian forint), IDR (Indonesian rupiah), JPY (Japanese yen), KRW (Korean won), MXN (Mexican peso), MYR (Malaysian ringgit), NOK (Norwegian krone), NZD (New Zealand dollar), PEN (Peruvian sol), PHP (Phillipine peso), PLN (Polish zloty), RON (Romanian leu), SEK (Swedish krona), SGD (Singaporean dollar), THB (Thai baht), TRY (Turkish lira), TWD (Taiwanese dollar), USD (U.S. dollar), ZAR (South African rand).

Share

Related articles