I Built a Web Scraper to Analyze the Economic Soundness of 200 Countries. Here’s What I Found

Alex the Younger
Keeping Stock
Published in
5 min readJun 3, 2019

--

Jame’ Asr Hassanal Bolkiah Mosque

I once read about the story of investor Jim Rogers, who for 3 years in the early 2000s, traveled the world in a custom Mercedes. He stumbled upon the country of Botswana and immediately fell in love with it. The government was very efficient and tended to take a more laissez faire approach to governing. He even met the president of the country who seemed to have a good understanding of economics. He bought every stock on their stock market (there were only 17 at the time), and made a very respectable return over the next decade.

That is the kind of gem I would like to find. Although I do not have the capital to travel the world as Jim Rogers did, I do have the internet, and I know how to write programs.

So I built a web scraper with Ruby and gathered the economic indicators that I felt were most crucial. I mistrust Keynesianism, and therefore mistrust country rankings created by mainstream economists. My main goal was finding countries that have not fallen prey to artificially low interest rates, mass government stimulus, or inflationary bank lending practices. There are many countries that, although might appear strong, are probably propped up by counterfeited money.

A word of caution, my analysis is still unfinished, and I think I still have much room to improve. The following countries are those that really caught my attention given the data I gathered. I hope it goes without saying, there are millions of other variables that go into judging something as complex as a country; please take this information with a massive salt block. The main indicators I used were: inflation rate, corporate tax rate, interest rate, unemployment rate, income tax, GDP per capita, government debt to GDP, banks balance sheet, central bank’s balance sheet, and government budget.

The Most Economically Sound Countries in the World

  1. Brunei
    I didn’t even know this country existed before building this scraper, but it seems to have good potential. About 800 miles away from Singapore, across the Pacific lies this little country of Brunei. Brunei has no personal income tax, no sales taxes, no form of Social Security tax. It has an inflation rate of -0.05%, meaning the standard of living is steadily increasing. This country, which is smaller than the state of Delaware, has a GDP per capita that’s higher than Russia, higher than Saudi Arabia, and nearly as high as Hong Kong. It has high interest rates compared to the rest of the world at 5.5%, which at first glance means it likely values thrift and savings more than reckless spending. It’s government has essentially no debt whatsoever, with a government debt to GDP at 2.4%. Statistics like this are unheard of in our world where economists and politicians basically suggest we “drive fast and leave a sexy corpse.” The data on its central banking system is somewhat mysterious, but from what data I was able to find elsewhere, it seems like their Central Bank is not actively inflating the currency and instead invests in “monetary gold and SDR’s” (SDR’s being a fiat currency created by the IMF in the 60s). As to what monetary gold is, I’m hesitant to think they’re referring to actual gold, I would assume they mean something along the lines of dollars or something relating to the Eurodollar system. Maybe someone else can interpret this information better than I can. Brunei will be on my radar from this moment out.
  2. United Arab Emirates
    The United Arab Emirates (UAE), like many middle eastern countries, has greatly benefited from oil reserves in the last decades. We’ve seen them flaunt their wealth, especially in Dubai, but the most amazing thing is that they may have the economic accounting to back up all of this wealth. They have a negative inflation rate at -2.5%, no corporate or personal income tax, 1.72% unemployment, 18% government debt to GDP, and a very low central bank balance on their balance sheet. They do have relatively low interest rates, but I would imagine the dollar plays a major role in these middle eastern countries and their wealth, as oil tends to be traded in dollars. Let’s hope they can maintain that wealth even if the dollar starts to decline.
  3. Kuwait
    Another oil king, Kuwait has one of the largest oil reserves in the world, but they also seem to have one of the best economies in the world. 0.8% inflation rate, no income tax, 15% corporate tax rate, 3% interest rates, 2% unemployment, higher GDP than Brunei, 14% government debt to GDP, and a relatively low central bank balance. Slightly higher interest rates at 3%, but bordering on the danger zone. I think we’ll see how a decline in the dollar effects these oil king countries.
  4. Hong Kong
    Hong Kong tends to always make the list for best economies in the world, probably for good reason. They have a 2.1% inflation rate, which is common, 16.5% corporate tax rate, 15% income tax rate, 3% unemployment, and a decently high GDP per capita. It does have a few smudges on its record. It has a little higher government debt to GDP than most on this list, at 38%, and although there is no data on its Central Bank’s balance sheet, we can tell that the local banks are doing quite a bit of lending themselves, it has the highest banks balance sheet number out of any other country on the list. Hong Kong might be a country on this list that is reaching its peak and looking down the road to decline.
  5. Russia
    It was very surprising to see Russia on this list. For a country that once killed approximately 1% of the world population under Stalin, they now seem to have their act together. They are one of the only countries in the world with enough reserves to pay off all of their liabilities. They’re not perfect, but they are certainly worth looking into. They have an inflation of 5.2%,(which is kind of high), but they make up for it in other ways. At first glance, they seem to have fewer taxes than the United States, with a corporate tax rate of 20% and a 13% income tax rate. They have a 13% government debt to GDP, and a very low central bank balance sheet. Interest rates are at 7.75%, which seems to suggest they’re not taking the fast money approach. The biggest smudge on their stats is that they have a lower GDP per capita than average at 11441. To put that into perspective, Hong Kong has a GDP per capita about 3 times that at 37927. So Russia still has some work to do, but it’s going in the right direction.

Here is the complete list of countries that stood out to me:

--

--

Alex the Younger
Keeping Stock

Satisfying my endless curiosity, and maybe yours too | Software Engineer | Praxis Alumni