Tuesday, May 15, 2012

Similarities between the Stock Market and Super Market




The original intent of setting up a stock market is to provide a source for companies to raise funds.  It is a place where companies can sell some of their shares to raise funds from the investing public. Another feature of the stock market is it provides liquidity to the investors. 


Unlike properties, where investors need to wait for months at end to complete the process of selling a property from putting up the property for sale to signing the Sales and Purchase Agreement.  
The stock market enables investors to complete a deal within days and hence can be considered quite liquid.

Another thing about the Stock Market is that it is somehow curiously linked to the real economy. It is said that the Stock Market is a barometer for things to come in the real economy. A rising stock market is presumably be followed by a strengthening of the economy and hence the public perception or confidence towards the economy and government. Rising stock markets also gives the perception that businesses will tend to invest more on plant and machinery.

Hence, the stock market has become an important tool for the authorities to influence the public mood and confidence since it is closely tied to the wealth effect of households and its consumption pattern. So it is not a surprise to see massive central banks intervention in the stock markets around the globe. How they control the stock markets?

Plunge Protection Team


The Plunge Protection Team normally are normally made up of private individuals from the investment banks, hedge funds and etc and regulators from the powers to be. For example in the U.S. the Plunge Protection Team or the President’s Working Group on Financial Markets (PWG) which comprises mostly of hedge fund managers. Its mission is to ‘develop and publicly release best practices so that market participants may enhance investor protection and systemic risk safeguards consistent with PWG principles and guidelines’. The committees are mostly from the hedge funds industry and they are,


1   Eric Mindich, Chair, Eton Park Capital Management 
2   Anne Casscells. AETOS Capital, LLC 
3   James S. Chanos, Kynikos Associates LP 
4   Anne Dinning, D. E. Shaw & Co., L.P. 
5   Jonathon S. Jacobson, Highfields Capital Management 
6   Marc Lasry,Avenue Capital Group
7   Edward A. MulĂ©, Silver Point Capital 
8   Daniel S. Och, Och-Ziff Capital Management 
9   Daniel H. Stern, Reservoir Capital Group 
10 William Von Mueffling, Cantillon Capital 
11 Michael Vranos, Ellington Management Group LLC

Getting people from the funds industry to head the Plunge Protection Team is like getting a fox to look after the chicken coop. Just wondered who are they going to bailout first (themselves or millions of folks out there) when the next crisis strikes.

In actual fact the main purpose of the Plunge Protection Team is to stabilize or rescue the financial markets when it is poised for a huge takedown or crash. They will stabilize the market so that investors will not get too worried or fear that the market is going to crash.

Controlling the Money Supply

The authorities in the Central Banks can control movements in the stock markets by manipulating the amount of money going in and coming out of the stock markets. They can use what we call the ‘Tight and Loose Money’ policies. 

By tight money, we meant by contractionary monetary policy whereby the authorities reduces the amount of money in circulation. As a result there will be less money available for speculation and investment and hence will cool down the stock market and economy.


By loose money, it will be the opposite where the authorities will implement expansionary monetary policies through reduction in interest rates and hence more money is available for speculation and investment.   

Management enriching themselves


As a result of such manipulations, the stock market is no longer what it used to be. The New Stock Market as it is called now has become more profit oriented and member companies treat it like a profit center other than a source to raise funds. For example there are many cases minority investors are being taken for a ride by the major shareholders and the management of the listed companies.
As a result of the fragmented ownership of the shares of the company, the management of the company are normally left to the management team. Instead of doing everything they can for the benefit of the shareholders they will do everything to enrich themselves because they are the ones that will determine the destiny of the company.


Other than this, major shareholders will also tend to overvalue their stocks. Corporations also need an overvaluation of the stockvalue. The reason being most of the executives wealth are tied to their stock holdings in the company either through Employee Stock Option Scheme (ESOS) and Stock splits. So it is not in their interest to have a beat down stock value. Corporate head honchos don’t make most of their money by increasing the sales of their company year on year or by churning out new products every now and then. They make most of their money by increasing or ‘Pump Priming’ the value of their company stocks. When their stock valuation reached obscene levels they will cash out in no time and often leaving uninformed shareholders in the lurch.


Stock Marketing Campaign by Companies


So how do the managers Market their Companies ? One of their best Marketing Strategy is to treat the Share Market like a Super Market. Why do say this? Take a look at the following and judge it by yourself and tell me whether there is any difference the way they run the Stock Market and a Super Market?



Column1Column2
Super MarketStock Market
Buy 2 Free 1Stock Split 2:1
End of Year SaleEnd of Year House Keeping
Cheap and GoodJunk or Penny Stock
Less fat and more leanAfter Restructuring
Good quality and can last for yearsBlue Chips with potential
Latest products with improved formula New issues with potential
Value for MoneyBonus Issue 1:1
Clearance SaleStocks Rebalancing
New ArrivalNew Listing
Product with potentialUndervalue Asset
Guarantee to lastNo downside risk
Hottest ItemOverbought
Products on OfferOversold
Rated best in its classAAA ratings
Clinically tested and provenResearch Dept analyzed and recommended
Easy to use - just follow instructionsEasy to open an account - Just sign here
Earn 3x points with credit cardOnly 3% charge on Margin Account
Incredibly low pricePenny stock about to bust
Once in a lifetime oppurtunityLimited downside and unlimited upside
Warehouse SaleMarket Crash
Only 3 leftBuy now or never


Lessons to Learn
1. So, the above are just some of the ways to make us believe that the stock market is always undervalue and sold at bargain prices. Hence overvaluation in the stock market is justified. Another good lesson to learn from this is that a lot of investors are blindly lead to the believe that Dividend Paying stocks are always good stocks. Think twice folks, I haven’t heard of many companies that operate just for the benefit of the minority share holders. By declaring dividends, the companies automatically made the stock cheap after their ex-date and hence increase their marketability.


2. Another trick that we need to be careful is that some companies either reduce or cancels the dividends and sometimes the dividend might be the last one they will ever announce. So investors that are hoping for a company that will continuously pay dividends will be in for a surprise.


3. The same goes for stock splits and bonus issue, it is another way of making the stocks more appealing to the public. This is because buying a stock worth $200 a share looks cheap after a 10:1 split which bring the value down to $20 a share., although it is still the same old original $200 a share.  


4. Another tactic they use to help them market their stocks after the announcement of the news on dividend or bonus issue is to collaborate with market makers to 'Push Up' their shares. What the market makers do is to play up the stock value as if there is no end to its rise. They are able to create an atmosphere where the new price seems like a new plateau for the stock. As soon as after the ex-date, the market makers who all the while have been buyers turned sellers. Needless to say the stock plunge and the minority or retail investors will be left holding the bag.

So next time a stock jobber tells you this and that about a stock, we just have to be careful and the best will be to do a background check on the company and its management..

Thursday, May 3, 2012

How High Frequency Trading are Ripping Off Investors

For the past few years there have been an explosion in High Frequency Trading in Financial Markets. HFT have been around for quite some time since the early days from Deutsche Bourse. Ever since then HFT has spread its wing into the futures , options and foreign exchange markets and it encouraged more brokers to engage in algorithmic and black box trading. 


HFT Activity is Gathering Pace

It is now estimated that daily trading volume in the US market consists of more than 70% HFTs, in Europe it has more than 60% penetration and here in Asia it is more than 50% with strong growth in Singapore, Taiwan, Hong Kong , Japan , India and China is set to triple its HFT trading by 2013.


When we talk about HFT, we talk about speed that is not in milliseconds but nanoseconds and also striving to achieve picoseconds or in other words their ultimate aim is the ‘race to zero’. HFT activities can be defines as a sudden surge of activities in the buy or sell order of a stock which last only seconds. The most striking event involves large peaks of activity separated by almost exactly the same time frame say 500 milliseconds. 
Since, the NYSE's matching engine is terribly slow (miliseconds not microseconds). Most HF strategies are being executed on Alternative Trading System Exchanges (ATS) such as ARCA, BATS or DirectEdge, all of which are much faster.


No human action can react to an event in a millisecond and the fastest we can achieve is around 140 milliseconds, and that’s only for a sudden activity like hitting the keyboard. About 25 years ago, trading of stocks is still done in an ‘open outcry’ trading pits where buyers and sellers close deals face to face. Now, it is done through roomful of computers via ‘matching engines’, where computer systems automatically match buyers and sellers.

Types of HFT algorithms

So what type of algorithms do they employ? There are many types of algorithms used by HFTs depending whether they are on the buy side or sell side. Some large brokerages like Goldman Sachs and Morgan Stanley are known to have an internal department specifically deal with HFT programming. What they have is basically a Core Program that is so flexible that different algorithms can be added in modular forms. Some of them have up to 50 different algorithms which can be switch at any time so as to avoid being tracked by their competitors. The following are some of the commonly used algorithms.

1)  VWAP or Volume Weighted Average Price. VeeWap as it is called does its slicing using statistical data on the volumes of shares that have traded in the equivalent time periods on previous days. The following is an extract from Themis Trading’s White Paper on Latency Arbitrage best explains how VWAP works.


Here’s an example of how an HFT trading computer takes advantage of a typical institutional algo VWAP order to buy ABC stock:

a. The market for ABC is $25.53 bid / offered at $25.54.

b. Due to Latency Arbitrage, an HFT computer knows that there is an order that in a moment will move the NBBO (Next Best Bid Offer) quote higher, to $25.54 bid /offered at $25.56.

c. The HFT speeds ahead, scraping dark and visible pools, buying all available ABC shares at $25.54 and cheaper.

d. The institutional algo gets nothing done at $25.54 (as there is no stock available at this price) and the market moves up to $25.54 bid / offered at $25.56 (as anticipated by the HFT).

e. The HFT turns around and offers ABC at $25.55 or $25.56.

f. Because it is following a volume driven formula, the institutional algo is forced to buy     available shares from the HFT at $25.55 or $25.56.
g. The HFT makes $0.01-$0.02 per share at the expense of the institution.

2)  The second type of algorithm is called the ‘volume participation’ which calculates the volume of a particular company’s shares bought and sold at a give time. This algorithm enables large investors to unload large block of shares with minimum slippage. If a large institutional investor unloads a large block of shares into the open market it will attract the attention of other investors. The result will be a change in strategy by its competitors knowing that a large block of shares being liquidated. So their competitor will sell at a lower price so as to front run the original seller. The opposite will happen if the institutional investor wants to buy a large block of shares will find that it will have to buy at a higher price. This is what they call ‘slippage’. 

So in order to avoid detection by its competitors, institutional investors can employ ‘execution algorithms’ to break down the large block of shares into smaller blocks. By selling smaller blocks of shares in the market, it will help to avoid creating any unnecessary attention to other market participants.


A sample programming code for the execution algorithm will be the following.

Procedure liquidate_stocks


Clear
Store 0 to xb1,xb2,xb3,xb4,xb5,xb6,xb7,xb8,xb9,xb10
Store 0 to xq1,xq2,xq3,xq4,xq5,xq6,x7,xq8,xq9,xq10
** The above set the memory variables to 0 for bid prices and quantity for the depth of 10 **
xb1 = b1
xb2 = b2
xb3 = b3
xb4 = b4

xb5 = b5
xb6 = b6
xb7 = b7
xb8 = b8
xb9 = b9
xb10= b10


** The above assign value to the memory variables for buy and sell prices for the depth of 10 **
morning = time('09:00:00')
midday = time('12;30:00')
afternoon = time('17:00:00')
Total_shares_sell = 500,000
min_selling price = 45.00
Stock_code = 'IATA'
xmarket_price = xb1

If Code = Stock_Code ** Code is the ticker code found in the exchange database **
Do while total_shares_sell > 0 .or. xmarket_price > min_selling_price  

If xb1 > min_selling_price then ** Make sure your selling price is higher than minimum **
Match_bid_qty   ** This is a function to sell at the bid price and quantity **
Total_shares_sell = Total_shares_sell - Match_bid_qty
xmarket_price = xb1

Elseif xb2 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty
xmarket_price = xb2

Elseif xb3 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb3

Elseif xb4 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb4

Elseif xb5 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb5

Elseif xb6 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb6

Elseif xb7 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb7

Elseif xb8 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb8

Elseif xb9 > min_selling_price .and. Total_shares_sell > 0
Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty

xmarket_price = xb9

Elseif xb10 > min_selling_price .and. Total_shares_sell > 0

Match_bid_qty  
Total_shares_sell = Total_shares_sell - Match_bid_qty
xmarket_price = xb10 

      Endif



readln(9,600,000,E,1,0) ** This part is for skipping for the next record **
** and setting the communication parameters for data acquisition *
xb1 = b1 ** This part is for assigning value to memory variables for the new record **
xb2 = b2
xb3 = b3
xb4 = b4

xb5 = b5
xb6 = b6
xb7 = b7
xb8 = b8
xb9 = b9
xb10= b10


Enddo
Endif


What the above code does is, it will instruct the computer to keep selling the inventory of IATA shares which is 500,000 lots till finish and the price must be above $45. It will only stop selling when,


1) all shares are sold 
2) if market price is below $45. 


I have not put in the lot size which can be 500 or 1000. More complex features can be added like since we know the total volume of bids through the xq1 - xq10. We can then add them up so that we can allocated a specific quantity to be sold at each price or what is known as 'Quantity slicing'.

3) Another type of algorithm that is designed to make money in the market is known as  ‘Electronic Market Maker’ algorithm. This type of algorithm mimics what human market maker does. And that is to continually look for spreads between the buy and sell prices and hence profits from them. Market maker algorithms are very complex and it requires artificial intelligence programming because the software needs to 'think and make decisions' at the same time. Such programs normally use the complex LISP or Prolog programming languages which is specifically designed to deal with artificial intelligence.

4) The fourth type of algorithm is the ‘Statistical Arbitrage’ algorithm which looks for price patterns to profit from. Some of the commonly used price patterns by institutional investors are moving averages and Bollinger bands. Institutional investors are known to use the MA50 or moving average 50 days to time the market.


They will fade in and out of the market using the MA50. When price drops below MA50 they will sell and vice versa. Upon knowing this HFT programs will calculate the price level at which it will goes below or above the MA50 days line. Hence they ‘front run’ the institutional investors by selling higher and buying lower.

Trading cycles what seems to be days and weeks now are being done in milliseconds and nanoseconds. In other words market has shifted from the traditional (fundamental and technical analysis) with long term holding for equity appreciation to short term trading that benefit only the speculators. The strategy of investing today refers to ‘here and now’ rather than ‘buy and hold’.

Anyway for further reading in HFT please refer to my one of my earlier post ( Feb 2012) on HFT’s role in destabilizing the financial markets. 


How to achieve such High Speed?

There are three methods in which they are able to operate in such high speed. 


  1. High Speed ultra low latency networks.  Corvil (www.corvil.com) is one of the leading supplier of unified application and network latency management system to Global Banks,Exchanges,ECNs, Market makers and service providers to the Financial Industry. According to them,

latency has emerged as a key factor in determining the level of success a particular automated trading or market making strategy achieves. Information about speed will become more valuable than speed itself”. Why do we say that?  It is very unlikely that you are going to be the fastest to every market you wish to trade, all of the time.

However, it is more reasonable to expect that you could be the fastest to some of the markets some of the time. Therefore it is critical to understand when you are likely to be fast and when you are likely to be slow across all paths of your trading network. If you know this, then you can decide where and when you should trade and increase the overall probability of achieving the desired fill.”


  1. Achieving speed through software based trading technologies. One leading supplier is Nanex Corporation. Nanex is the developer of NxCore, which is a streaming WHOLE MARKET data feed (ticker plant) and comes with an API (Application Programming Interface) for developing your own trading software. It essentially brings the whole market, like the hyperactive US Options Market (OPRA) which transmits over 1.7 million quotes per second to your desktop. NxCore only requires a low end Pentium 1.0 Ghz with 80Mb hard drive to receive and database 1.4 million quotes per second or over 6 billion quotes per day and with a CPU usage of less than 5%. It can accomplish this task is because of its award winning proprietary data compression technology. It is basically like Co-Locating your PC next to the Data Farm Servers in NYSE.  


  1. Now the latest being the move to hardware based algorithms and matching engine on a chip. This is called the FPGA or Field Programmable Gate Array and is a chip that can be programmed to reduce hardware latency. Due to its infancy, there has yet been a widespread in its use most probably due to its cost. However due to the advancement in technologies higher capacity chips such as the 16, 32 and 64 core chips with hundreds of gigabytes bandwidth will be available at a lower cost in the near future.

How HFT ripped off Investors?

So with all these advantages, the following are five of the common tactics used by HFTs to ripped off ordinary investors.


1) During a normal trading, market prices for stocks will be gyrating up  and down, regardless of the real world economic conditions. It is the HFTs that will determine the overall market direction, usually without fundamental or technical reason. And based on a few lines of code on their algorithm in ramming up share prices without any fundamental reasons like a Merger or Takeover, better than expected profits or even any good news, retail investors get suckered into buying shares in a rising market.Sometime you will see stock prices moves up and down 5-10 bits for no possible reasons.


And when retail investors started to chase or liquidate their holdings, the buyers and sellers simply disappeared from the screen. So in a way HFTs are actually perpetuating the same Ponzi Market Scheme  as in the Madoff case, but on a massively larger scale.According to an article by AT, HFT trading has become the biggest profit center for Wall Street and the following is the excerpt.


"Proprietary trading takes in a number of unique strategies, including market making, arbitrage (ETFs, futures, options), pairs trading and others based on the linked trading of more than one asset class, e.g., futures index and cash equities. In fact, TABB Group estimates that annual aggregate profits of low latency arbitrage strategies exceed $21 billion, spread out among the few hundred firms that deploy them."


2) Moreover, HFTs are also responsible for most of the FALSE BREAKOUT  in the Index and individual Shares. Most of the time when we  see that the index or individual shares breaks new high during the intraday trading only to give back most of its gains towards the closing. Hence, those who are using technical analysis to trade the markets believing that the market is going for a new high will always left holding the baggage at the end of the trading day. Then when the market opens tomorrow, it will start plunging and there will be force sells of shares on its way down. This is how the game is played and if you are not aware of such manipulations, then you shouldn’t be in the market at all. 


Not only ordinary folks got smacked but institutional investors as well. Hedge funds and Institutional investors also got bewildered and confused by the price actions. Instead of managing 20-30 stocks they are now concentrating on 2-3 stocks and engaged in what we called ‘all in one shot’ investing. That means they are betting in a one way market movement, either long or shot. 


3) The Industry is biased towards the ‘Big Money’ because that is where the money is and at the expense of ordinary folks like us. The big boys are allowed to do what nobody could do in the old fashion floor trading. 


Traditionally a broker would be asked to leave the floor in a few minutes , if he systematically placed orders to see how other or the market maker reacts and then cancel the orders after receiving the information. HFT operators are allowed to cancel hundreds of their orders daily so they can camouflage and at the same time gauge the presence of their competitors.  Evidence of biasness  can be found in the following articles.  


From the NYSE 
"NYSE Technologies, the innovative commercial technology unit of NYSE Euronext, today announced the launch of its next generation market data infrastructure, NYSE Technologies’ Market Data Platform V5. This revolutionary ticker plant technology is designed specifically for high-volume and latency sensitive markets, delivering data in microseconds rather than milliseconds. It offers 10 times the overall performance of previous generation market data platforms while allowing customers to reduce their hardware footprint by as much as 80%."


"NYSE Technologies’ performance benchmarks, certified by Intel Fastlab, confirm that Market Data Platform V5 offers continuous throughput of 500,000 messages per second on a single CPU core, with a mean latency of less than 40 microseconds over Remote Direct Memory Access (RDMA) and an ultra-low latency range of 10-20 microseconds over Local Direct Memory Access (LDMA) – ideal for co-location servers."


Also according to HFT sites such Lime Brokerage that promotes hardware co-location:
"Lime Brokerage also encourages clients to co-locate their servers in our Jersey City data center by offering extremely competitive rates. By co-locating, clients can feel confident that their servers are connected directly to the primary switch, which minimizes latencies in the order transmission process."


4) Co-Location enables what we called ‘Queue Jumping’. Queue Jumping refers to a situation where jump the queue to be filled first even though others are in the queue first. I myself had experience such a situation where I put up a bid for a stock. At that time there are only 530 lots queue up for the bid and I know mine is the last 30 lots because when I keyed there are 500 lots on the queue. About a minute later the lots on the queue expanded to 930 lots. 


Then about 3 minutes later, there were a few transactions done and the total is 600 lots. So by right my 30 lots should been filled but when I checked my order screen it is still queuing. Since my order was in between the 500 – 530 lots vicinity, it should have been filled. But too bad someone else got filled at my expense. Of course, you know what happens next, the stock is screaming up north.


The problem with the system is that our buy or sell order slips is time stamped to the latest 1 second at best. We do not know what happens in between the 1 second. There is no proof of who is on the queue first because it is not timestamp in milliseconds. But now we know, it is the job of the HFTs. Our orders are not assigned a queue number so as to say. Say if mine is 3 and if there are a total of 23 people queuing, then mine will get filled after the first two. But most trading platforms don’t offer such facilities and orders from HFTs will be filled first due to their speed of execution.


5) Co-Location certainly has its advantages over orders that come from servers located elsewhere. Co-locate not only gives you blindingly fast speed (about 10GB+) but also reliability because their software resides in the same hardware.
Another advantage of co-locate is whenever there is a financial market meltdown, being a few feet away from the exchange server is definitely better than being a few hundred kilometers away. Execution of orders will definitely faster and smoother (jammed free) than orders that are being routed from elsewhere. I am sure most of us encountered situations where our orders are minutes in delayed during times of panic like during the 2008 market meltdown.


By the time our order appears on the screen the share price most probably had dropped 10-15 bids. Whereas, those folks who co-locate their terminals, will probably get their orders filled instantaneously.  

Evidence of HFT Presence

How can we detect the presence of HFT activities in the market. Since HFTs algorithms generates buy and sell orders with the same quantity of stocks with the same time interval, it will no doubt will leave behind a so called ‘money trail’. So by looking at chart patterns and also the audit trail on the stock tracker, we are able to visualize their presence. The following chart pattern by Nanex Corporation (www.nanex.net) shows different strategies employed by HFTs.

07-27-10 
NASDAQ "Blotter". One of the more unusual repeating Asksize cycles


07-28-10 
BATS "Batsicles". BATS price cycling through a large price range, each intermittent with a stub quote, drop it down and start over.


07-23-10 
BATS "Stubby Triangles". Drop the quote from a valid price to 0.001 and then back up to a lower price level. When the new price level hits 0.001 as well, do it all over again at approx. 380 times a second.



07-13-10 
BATS "60-Step". Symbol SAH. Take sixty steps up (a penny at a time) and one step down (0.60), reset and do it all over again (at approx. 700 times per second)






The following are some screen shots that I have taken from the Jakarta Stock Exchange via the OMS platform and the timeframe is the 1 minute chart. The following screen shot shows how a HFT algorithm in action. The counter that I am referring is IATA. As you can see from the screen below, as of the starting time at 14:56:21, there are multiple orders being filled by the buyer with exact 25 lot sizes.
I have counted and there are a total of 50 orders being filled with evenly 25 lot size. As you can see there would be no human intervention in this kind of situation because the fastest reaction we can do is about 140 milliseconds. To key in 50 orders of similar lot sizes within 500 – 1000 milliseconds is out of the question.







As you can see from the second screen, the price of the stock was push down from 80 to 77 at about that time. Then in the next few minutes the HFT began to push up the price of the stock to 81. Can you see the sudden outburst of volume at the bottom of the screen. So, all in all this process only lasted a few minutes and it is very difficult for us to capitalize on such situations.