If countries are stocks, which ones should you long & which ones to short?

I used machine learning to grade the industrial health of 190 countries over 30 years. Here’re results on China, US, India & more.

See which countries I’m bullish & bearish about for the next decade 👇

First, a word on how this is done. My coauthor (Xuege Zhang of Carnegie Mellon) & I used ML algorithm to figure out which products each country should export, given the country’s unique combo of traits. (full paper linked at the end if you’re curious).

We then check if a country is indeed exporting what it should export. Each country gets a “health score” of their export portfolio every year. It essentially measures the similarity btw actual exports and algorithm’s recommendations:

higher score = healthier economy.

We found this export health score to predict GDP growth and growth volatility pretty well, that is, the higher the score, the higher & stabler a country’s economic growth.

Why so?

It’s just like your personal health. You can get energy by drinking a lot of coffee, or by having an exercise & diet regime tailored to your unique needs. The former is a short term fix. The latter gives you sustained vitality in the long term.

For an economy, the short-term fixes are things like monetary easing, fiscal stimulus & export price increase. But for growth to last, the economy needs to be “structurally sound”— its industrial structure needs to tailor to the country’s true fundamentals.

The export health score is a measure of this “structural soundness”.

What does this look like for actual countries? Let’s check out a few.


Since China joined WTO (2001), the health score (Y axis) has been shooting up in a straight line, going from below world-average to above 90th percentile. Few countries have seen a rise this big.

Say what you want about China’s recent tech crackdown. It’s the CCP’s way to trim off excesses so that the economy remains structurally sound for the long run.

The CCP has done that before and will do it again. This is not “walking back from market economy” as most American pundits made it to be. (I promised to write a thread on the crackdown and I will. It’s coming!)

There’ll be more short term pain for investors from recent regulatory actions. But overall I’m highly bullish on the Chines economy. The structural soundness of its tradable sector is a big part of my confidence.

But you say, what about the real estate bubble, the insolvent banking sector, the over investments, the demographic change & (insert other million problems of China)?

This is where you need to think in relative importance of different factors. The health of industrial sector is of 1st order importance and a reliable long-run predictor. If a country gets this right, it can afford to make many other mistakes and still do ok.


The health score for the US has been trending down and hovering around world medium for the past 2 decades. I don’t like how this trend looks.

A large part of this is because of the hollowing out of industrial sector. It has many causes, among which, the Dutch Disease from the “USD export” trade that I wrote about before.

The US now has one of the smallest industrial sectors among major economies.

Ignoring the industrial sector for over 2 decades was a big mistake. This is the sector that creates:

1) 95% of patents & technology progress

2) huge productivity spillover to rest of economy

3) lots of employment that in turn supports middle class & creates domestic demand

But notice in the US chart that the health score has turned up a bit in the last couple years. So my hope is not lost yet. US industries urgently need a “Build Back Better” agenda and this decade is a crucial turning point for that to happen…or not.


Not a pretty sight. The health score was high 35 yrs ago and has been dropping since. Now it’s barely above world medium.

The country had the potential to become an industrial superpower. Instead it turned to service exports like IT & back office support for growth.

The problem with that strategy is it requires lots of human capital, and doesn’t help the vast majority of the population that is poorly educated. Instead of growing the middle class and building lasting domestic demand, it aggravates the gaping inequality even more.


Germany’s had a near perfect health score for almost 3 decades 😍 It’s dropped a bit in recent years but is still higher than 95 percent of all countries.

It’ll continue being the economic leader of Europe. I don’t see that change anytime soon.


Russia’s health score has been declining since the GFC and is now the lowest among the BRICS. Half the economy relies on handouts from oil exports and everything else seems to shrink by the day.

If I lived there, I’d be trying to get out as fast as I could.


Charles de Gaulle said: “Brazil is the country of the future and always will be.”

60 years later he’s still right. The country is a forever over-promise-and-under-deliver. After a hopeful rise in export health score in the 90s, industrialization stalled.

In recent years Brazil’s settled for being a pure-bred commodity exporter, which means it won’t starve, but probably won’t be the breakout success it promised to be, either.

(BTW, like this so far? I write about ideas on investment, macro and human potential. Subscribe to my newsletter for updates.)

Let’s also look at a few smaller economies.


The health score has dropped somewhat in the last 20 yrs but is still in the top 20 of the world, which tells you how high it was in the past.

No reason to be bearish on Korea yet, but no reason to add to your position either.


This country is the poster child of Asian stereotype— well-adjusted, clever, productive and reliably boring.

Health score has been steadily rising. Now in the top 25 of the world. The economy is as diversified as can be. And unlike Korea or Japan, it’s a relatively open society (by Asian standards anyway), which allows it to attract top talents from outside.

Very bullish.


It was transferred back to China in 1997 and health score has been dropping since. China opened up & mainland economy boomed, while Hong Kong lost some of its value prop as trade/finance bridge to China and is struggling to find a new one.

Doesn’t look like the score is coming back up anytime soon. Not a place I’d invest, though the food is out of this world.


Since the Panamanians took over the canal (1999), the economy has been on a tear. With logistics, tourism, oil, copper, gold, finTech & manufacturing, the little central American country is surprisingly diversified and has many blessings to count.

Real estate has been tanking the past few years after a decade-long boom. It may have bottomed recently. If you’re going to bet your money anywhere in LATAM, Panama should be one to look out for.

The paper is still a work in progress. But here’s a rough draft (pardon the construction dust 🛠) if you want to check out the nitty gritties. I’ll also push the source code to GitHub once it’s finalized.



  1. Christian Müller Reply

    I like your analisis, very easy to read! The chart with all the bubles is hard to read though, should allow zoom in to see each data point.

  2. Nice work any data on Canada? Middle East? gulf countries?

  3. Interesting insights. Though need to understand your methodology further. Is the paper available to read?

  4. Mahtab Syed Reply

    This is very good. Can I see results for Australia?

  5. Bob Gattis Reply

    Nice paper. I missed seeing a table of results that identified the country abbreviations, as well. Some are obvious, but not all. Thanks for the work!

  6. getfundedafrica Reply

    Interesting article. Can you share the results for African countries? Better still, when can access be provided to the breakdown by country? Thanks!

  7. Just a few weeks ago I started doing something similar based on the Economic Complexity Index (https://atlas.cid.harvard.edu/rankings) after reading Why Information Grows by Cesar Hedalgo which is a measure focused also on the “social fabric” and export add value. Gives similar results!

    I am adding another layer of Liquidity by country (as it drives business cycles) after reading Capital Wars by Michael J. Howells to see if I can get good correlations to each country openly traded Market Cap. The idea is to build an ML based good/long-term systematic, macro allocator algorithm.

    Code is pushed ing Github (see some country examples here: https://github.com/enissay14/systematic-macro/blob/main/data_prep.ipynb)

    Cool blog Tascha (from another RV power user!)