How to build a macro trading strategy (with open-source Python)

This post is a condensed guide on best practices for developing systematic macro trading strategies with links to related resources. The focus is on delivering proofs of strategy concepts that use direct information on the macroeconomy. The critical steps of the process are (1) downloading appropriate time series data panels of macro information and target returns, (2) transforming macro information states into panels of factors, (3) combining factors into a single type of signal per traded contract, and (4) evaluating the quality of the signals in various ways.
Best practices include the formulation of theoretical priors, easily auditable code for preprocessing, visual study of data before and after transformations, signal optimisation management with statistical learning, and a protocol for dealing with rejected hypotheses. A quick, standardised and transparent process supports integrity and reduces moral hazard and data mining. Standard Python data science packages and the open-source Macrosynergy package provide all necessary functionality for efficient proofs of concept.

(more…)

Using principal components to construct macro trading signals

Jupyter Notebook

Principal Components Analysis (PCA) is a dimensionality reduction technique that condenses the key information from a large dataset into a smaller set of uncorrelated variables called “principal components.” This smaller set often functions better as features for predictive regressions, stabilizing coefficient estimates and reducing the influence of noise. In this way, principal components can improve statistical learning methods that optimize trading signals.

This post shows how principal components can serve as building blocks of trading signals for developed market interest rate swap positions, condensing the information of macro-quantamental indicators on inflation pressure, activity growth, and credit and money expansion. Compared to a simple combination of these categories, PCA-based statistical learning methods have produced materially higher predictive accuracy and backtested trading profits. PCA methods have also outperformed non-PCA-based regression learning. PCA-based statistical learning in backtesting leaves little scope for data mining or hindsight, and the discovery of trading value has high credibility.

(more…)

How macro-quantamental trading signals will transform asset management

Macro-quantamental indicators and trading signals are transformative technologies for asset management. That is because they allow plugging point-in-time fundamental economic information into systematic trading, backtesting, and statistical learning pipelines and remove an important barrier to information efficiency. While the predictive power of macro information for asset returns has been evident for decades, its use in systematic trading and research has remained rare. This disconnect reflects the historical difficulties of replicating past data and analyses point-in-time and the need for expert curation of data updates going forward.

Macro-quantamental signals allow systematic trading to become more informed and make prices more “anchored” in economic reality. Value generation is not merely a zero-sum game but also a profit share from a more efficient financial system. The principles of quantamental success are the faster pricing of macroeconomic developments, the correction of implausible risk premia, the adjustment of evident price-value gaps, and an improved pricing of market “setback risks”. Empirical evidence has shown macro-quantamental signals succeeding in many areas, including market timing, enhancement of trend following, improvement of risk premium strategies, equity allocation, and higher-frequency information change-based strategies. Macro quantamental signals also integrate neatly with statistical learning.

(more…)

Macro information changes as systematic trading signals

Jupyter Notebook

Macro information state changes are point-in-time updates of recorded economic developments. They can refer to a specific indicator or a broad development, such as growth or inflation. The broader the economic concept, the higher the frequency of changes. Information state changes are valuable trading indicators. They provide daily or weekly signals and naturally thrive in periods of underestimated escalatory economic change, adding a layer of tail risk protection.
This post illustrates the application of information state changes to interest rate swap trading across developed and emerging markets, focusing on six broad macro developments: economic growth, sentiment, labour markets, inflation, and financing conditions. For trading, we introduce the concept of normalized information state changes that are comparable across economic groups and countries and, hence, can be aggregated to local and global signals. The predictive power of aggregate information state changes has been strong, with material and consistent PnL generation over the past 25 years.

(more…)

Inflation and equity markets

Jupyter Notebook

Rising inflation is a natural headwind for equity markets in economies with inflation-targeting central banks. As consumer prices accelerate, expected monetary policy rates and discount factors tend to increase more than dividend growth. Over the past three and a half decades, there has been a strong negative correlation between changes in reported inflation and simultaneous global equity futures returns. A similar negative relationship is evident between seasonally adjusted CPI trends and concurrent returns.
Furthermore, inflation dynamics have shown predictive power. Short-term changes and trends in consumer price growth have proven to be valuable early warning signals for serious market downturns and leading indicators of recoveries. Also, inflation-sensitive strategies have performed on par with long-only portfolios during stable periods. Overall, they enhanced risk-adjusted returns by improving the timing of equity risk exposure.

(more…)

Statistical learning for sectoral equity allocation

Jupyter Notebook of factor calculation Jupyter Notebook of statistical learning

There is sound reason and evidence for the predictive power of macro indicators for relative sectoral equity returns. However, the relations between economic information and equity sector performance can be complex. Considering the broad range of available point-in-time macro-categories that are now available, statistical learning has become a compelling method for discovering macro predictors and supporting prudent and realistic backtests of related strategies. This post shows a simple five-step method to use statistical learning to select and combine macro predictors from a broad set of categories for the 11 major equity sectors in 12 developed countries. The learning process produces signals based on changing models and factors per the statistical evidence. These signals have been positive predictors for relative returns of all sectors versus a broad basket. Combined into a single strategy, these signals create material and uncorrelated investor value through sectoral allocation alone.

(more…)

Cross-country equity futures strategies

Jupyter Notebook

Developing macro strategies for cross-country equity futures trading is challenging due to the diverse and dynamic nature of equity indices and the global integration of corporations. This complexity makes it difficult to align futures prices with country-specific economic factors. Therefore, success in cross-country macro trading often relies on differentiating indicators related to monetary policy and corporate earnings growth in local currency. Additionally, cross-country strategies benefit from a broad and diverse set of countries to generate value consistently.
We tested five simple, thematic, and potentially differentiating macro scores across a panel of 16 developed and emerging markets. Our findings suggest that a straightforward, non-optimized composite score could have added significant value beyond a risk-parity exposure to global equity index futures. Furthermore, a purely relative value equity index futures strategy would have produced respectable long-term returns, complementing passive equity exposure.

(more…)

Macro-quantamental scorecards: A Python kit for fixed-income markets

Jupyter Notebook

Macro-quantamental scorecards are condensed visualizations of point-in-time economic information for a specific financial market. Their defining characteristic is the combination of efficient presentation and evidence of empirical power. This post and the accompanying Python code show how to build scorecards for duration exposure based on six thematic scores: excess inflation, excess economic growth, overconfidence, labour market tightening, financial conditions, and government finance. All thematic scores have displayed predictive power for interest rate swap returns in the U.S. and the euro area over the past 25 years. Since economic change is often gradual and requires attention to a broad range of indicators, monitoring can be tedious and costly. The influence of such change can, therefore, build surreptitiously. Macro-quantamental scorecards cut information costs and attention time and, hence, improve the information efficiency of the investment process.

(more…)

How to adjust regression-based trading signals for reliability

Jupyter Notebook

Regression-based statistical learning is convenient for combining candidate trading factors into single signals (view post here). Models and signals are updated sequentially using expanding time windows of empirical evidence and offering a realistic basis for backtesting. However, simple regression-based predictions disregard statistical reliability, which tends to increase as time passes or decrease after structural breaks. This short methodological post proposes signals based on regression coefficients adjusted for statistical precision. The adjustment correctly aligns intertemporal risk-taking with the predictive power of signals. PnLs become less seasonal and outperform as sample size and statistical quality grow.

(more…)

Reported economic changes and the Treasury market: impact and payback

Jupyter Notebook

Financial markets pay great attention to reported changes in key economic statistics, particularly when they are unexpected. For quantitative analysis, we introduce the concept of information state changes and the methods of aggregating them across time and indicators. We apply these to a few popular U.S. indicators and investigate how information state changes have affected the bond market. In line with theory, monthly changes in economic growth, inflation, and employment growth have all been negatively correlated with concurrent Treasury returns over the past 25 years. However, there has been subsequent payback: the correlation reverses for subsequent monthly Treasury returns. This supports the hypothesis that high publicity volatile indicators are easily “overtraded.” Cognitive biases may systematically exaggerate positioning toward the latest “surprises” or publicized changes.

(more…)