Saturday, October 15, 2011

The Twitter Hedge Fund Series: Using Twitter As a Sentiment Indicator - Part 1

I was reading a paper entitled Constructing consumer sentiment Index for U.S. Using Internet Search Patterns by Messrs  Nicolas  Della Penna and Haifang Huang, when it occurred to me that their methodology could be applied to Twitter.


In their paper, Messrs Penna and Huang assert the following:
  • The search term "Bankruptcy" is an indicator of adversarial financial conditions. The higher its frequency; the more adversarial the financial conditions.
  • The search phrase "Office Furniture" is an indicator of improving business conditions. The higher its frequency; the higher the vibrancy of business conditions.
  • The search phrase "Luxury Goods" is an indicator of increasing willingness to spend on discretionary items. Generally, the higher its frequency; the more bullish the economic outlook.
  • The search phrases "Oil and Gas", "Electricity", "Alternative Energy" and "Hybrid vehicles" indicate attention to energy cost - which shows a bearish outlook. The higher their frequency; the more bearish the economic outlook.
As a rough test of the applicability of their methodology to Twitter, I picked the terms "Bankruptcy", "Luxury"and I extracted the frequency with which they appeared in tweets from the 24th of April to the 9th of October. Here is what I got:

Chart 1: The encircled points indicate the things that immediately stood out
Click on image for better visibility


Find below my commentary on each of the points:
  • The first encircled point between 1-8 May: Here the term 'Luxury' is twitted with the greatest frequency. And the differential between the frequency with which the term is twitted  and the frequency with which the other terms are twitted is at its greatest. This indicates that the outlook around the 5th of May was at its most bullish. Since the S&P 500 is an indicator of general market sentiment, this should reflect in the index anytime between the 1st and the 8th.  However, in chart 2, the S&P 500 actually is on a downtrend during that period... Nonetheless, I would be interested in finding out how stocks of luxury oriented products performed then.
  • The second encircled point between 12-19 June: The frequency with which the term 'Electricity' appears in tweets hits a peak, 'Bankruptcy' also hits a peak and while 'Luxury' is on a dip. In aggregate, this indicates bearish sentiment. In Chart 2, between June 13 and June 14 the S&P 500 actually dips -  i.e. the market trend is in sync with the twitter trend! As a side note, I would be interested in finding out how energy stocks performed then.
  • The third encircled point between Jun 26-July 3: 'Bankruptcy' hits the highest peak and the other two terms also peak. In aggregate two out of the three indicators indicate bearish sentiment. So, this should be taken as a sign of bearish sentiment. In chart 2, the S&P 500 actually dips between the 26-28th of July -  i.e. the market trend is in sync with the twitter trend! As a side note, I would be interested in finding out how an index of luxury stocks performed then.
  • The  forth encircled point between August 28 and September 4: 'Bankruptcy' hits a trough and 'Electricity' and 'Luxury' are on an uptrend. Two out of the three indicators are bullish, so this should be a sign of a bullish outlook. In chart 2, on the 29th of August the S&P 500 opened at 1,177.91 and closed at 1,210.08 -  i.e. the market trend is in sync with the twitter trend! As a side note, I would be interested to find out how energy stocks performed during that time period.
Chart 2 below shows points that correspond with the discussed sentiments:


Chart 2 S&P 500 movements that correspond to the sentiment terms
Click on Image for better visibility

Although I used a very crude method, the sentiment indicators do appear to have some reflective power. So, I will dig deeper to see if they may have any predictive power.


I'll first start by creating a content aggregator that draws each of the above mentioned terms from Twitter. For this exercise I will use Yahoo Pipes and my aggregator  looks like this:


Chart 3: Content Aggregator
Click on Image for Better Visibility


The data feed that I will mine and draw trends from can be accessed from here  (Click on the 'List tab'for the aggregated raw tweets)

In a subsequent post I will create a Twitter sentiment indicator, from the data I draw from the aggregator, and see if it has any predictive power.


Stay tuned, that is the interesting part!

Tuesday, September 6, 2011

Going Back to the Gold Standard

Over a year ago, I wrote a blog post on the specie gold standard 'method' of money supply management. At that time, I was certain that this would be the last blog entry I would make on this subject (I don't like blogging about gold). However, recent occurrences in the Eurozone (and the US) have forced me to reflect again on this topic:

In this post, I will conduct a thought experiment on the implications of returning to the specie gold standard of money supply management.

Let us postulate that the world returns to the specie gold standard of money supply management, and that the system possesses the following features:
  • All forms of money in circulation in each country, i.e.; M0, MB, M1, M2, M3, MZM, represent actual gold in the vaults of each respective country's Central Bank.
  • Whenever Nation X imports goods/services from Nation Y, gold that is comensurate with the value of the traded goods/services, is shipped from the vaults of Nation X's central bank to the vaults of Nation Y's central bank. Thus, this implies that imports deplete a country's gold reserves and its money supply, and; that exports grow a country's gold reserves and its money supply.
What would happen in such a system?

1) The Fractional Reserve System would create less money

Currently, banks around the world (except those in Islamic countries) employ the fractional reserve system to create money.

What is it? This is best illustrated by way of an example. Let's say that a bank receives $1,000 in clients' deposits. In this country for every $1 transaction that occurs in cash, 7.33 times the number of cheques are accepted. The bankers are unsure about the frequency of withdrawals, so they decide to leave the depositors' money untouched.

People trust the banking system and each other, and cheques are as good as cash. Hence, instead of lending the depositors' funds to borrowers, the bank can simply issue cheque books, that correspond to the amounts that each borrower seeks. And, the borrowers could write cheques up to their respective requested loan amounts.

Being rational people, with MBAs from IMD, INSEAD and Harvard Business school, the bankers decide to gain operational leverage from the community's trust by lending 7.33 times their cash base; i.e. the bank lends $7,333.33. Thus, each dollar of depositors' funds creates $7.33 dollars worth of loans in this scenario!

Contrastingly, If the specie gold standard, with the above mentioned features, was introduced, $1 worth of depositors' funds would create $1 worth of loans. Succinctly, credit, the lifeblood of the modern economy, would immediately dry-up, and this would trigger either a recession or a depression in most jurisdictions.

Simply put, the gold standard would reduce: economic growth, living standards, job creation and societal stability. Further, the gold standard would reduce the likelihood and severity of credit-induced crises, like the subprime mortgage crisis of 2007-2009. So, its disadvantages do come with an important advantage.

2) Barter Transactions would rise exponentially

To satiate human beings' unlimited needs and wants, commerce has to occur. And, money is the lubricating force of the world's engines of commerce.

The main problem with using gold as a unit of account, through the employment of the specie gold standard, is its scarcity. There is not enough gold in the world to support the volume of transactions that occur in the modern economy every day. Stated otherwise, if the specie gold standard was reintroduced, the scarcity of gold would be a checking mechanism that would curtail people's ability to satisfy their needs and wants through commerce.

It is reasonable to assert that people would circumvent the above mentioned problems by batering the goods they produce for the goods they need.

In short, the gold standard would morph the world economy into the Burning Man festival! I'm not to sure whether this is a bad thing or a good thing.

3) The rise of beggar thy neighbour protectionism

As was mentioned eslewhere, imports would drain countries' gold reserves. And, this would, in turn, cut money supply and curtail economic growth. Clearly, this is undesirable for most governments, and thus, they would institute tarrif and non tarrif barriers to imports, while vigorously promoting exports, in a bid to maximize gold reserves.

Simply put, this would trigger beggar-thy-neighbour protectionism. And, this could start a depression as acute as The Great Depression.

Still want to return to 'The Gold Standard'?