Tag Archive for 'High-frequency Trading'


HFT and frontrunning

I am not a finance guy and I almost certainly don’t know what I’m talking about when it comes to high-frequency trading (HFT), but if ignorance stopped people giving their opinions on the internet, all we’d have left would be pornography and we don’t want that, do we?

A friend sent me to this opinion piece by Alan Kohler, a journalist at the ABC (that’s the Australian Broadcasting Corporation, for any Americans in the audience).  He’s terribly worried about HFT in general and front-running in particular.  I can’t be bothered quoting him — you can click through and read it for yourself if you like.  Go on, I’ll wait.

At first, I couldn’t see how anybody could legally front-run me.  I wrote this in reply to my friend:

Suppose that I’m a buyer.  My order is:

* I want to buy up to W shares

* The last transaction price was X per share

* I will pay no more than Y per share

* If there are any shares on offer for a price lower than or equal to Y, the following applies:

* Take the lowest asking price that is less than Y.  If the quantity available for sale at that price is greater than X, I’m done.  If the quantity available at that price is less than W, then look for the next-lowest asking price that is less than or equal to Y.  Repeat as necessary.

* If I end up buying everything on offer for asking prices less than Y and I still haven’t filled my order, the remainder is left as a bid at price Y.

So the “normal” way of buying shares — walking up to your broker and saying “10 shares, please”, is just a way of saying “W=10, Y=infinity”. It’ll get you 10 shares at the current prevailing price.

I can see how my broker could front-run me:  After getting my order, they could buy up everything with an asking price lower than my Y and then sell it to me at Y.  But (a) it’s illegal for brokers to do this; and (b) the whole point of my saying that I’m happy to buy them at price Y is that I’m happy to buy them at price Y.

I cannot see how an entirely separate company can front-run me.

Then a second friend pointed out that the front-running is really against institutional players in the market.  In reply to him, I described it like this:

1) I’m an institutional buyer (presumably an institutional seller would just have everything in reverse). The current price of the stock (i.e. the last transaction price) is X. I think that it’s worth at least Y now and that it will, over time, eventually be worth Z, with Z > Y > X. I want to buy 1 million shares at as low a price as possible but no higher than Y. There are more than a million shares available in existing quotes with asking prices between X and Y.

2) Rather than spook the market, I send in a stream of buy orders. Say, 100 orders for 10,000 shares, with the bid price for each gradually rising with whatever ask quotes are available.

3) The HFT dude is sitting right next to (or even inside) the exchange and sees this stream of orders coming in and being filled sooner than regular market players.

4) He doesn’t know it’s me sending them in and he doesn’t know my cut-off quantity or my cut-off price, but simple logic says if I’ve just sent in 9 orders for 10,000 shares each, I’m probably going to send in a 10th, too.

5) Making an intelligent guess that I will, he (very) quickly throws an order into the exchange to buy (say) 10,000 shares at the current asking prices and then once he’s got them, puts them up for sale again a fraction of a cent per share higher. He can do this offer to buy, complete the transaction and offer to sell before I get around to submitting my 10th order precisely because he’s so close to the exchange.

6) My 10th order comes in and since the (new, higher) asking price is still below my cut-off price, I happily buy them off the HFT dude.

7) Repeat until I finish buying 1 million shares or the price rises to Y, in which case I stop early.

I might still have that wrong (and if anybody with actual knowledge sees any mistakes, please do correct me), but for the moment I’ll suppose that I’ve got the basics down.  Here are my thoughts, in handy bullet-point form:

  • Recognising the presence of the HFT dude, the rational thing for the institutional buyer to do would be to randomise the size and timing of each order they send in to mimic a bunch of smaller players. I assume this happens.
  • To the HFT dude, a sequence of buy orders from a single purchaser and a sequence of buy orders from a collection of different purchasers would therefore be observationally equivalent. The HFT dude is therefore just a momentum trader.
  • At worst, the HFT dude is unmasking the institutional buyer’s desire to stay hidden.
  • Let’s say that the institutional buyer’s current valuation of Y is correct. Absent the HFT dude, the original sellers lose (because they sold at prices below Y) and the buyer gains (because they bought at prices below Y). With the HFT dude, the original sellers lose the same amount for the same reason and the buyer is forced to split their gain with the HFT dude.
  • But if the true value of the stock really is Y, the presence of the HFT dude simply moves the price towards Y more quickly. The market is indeed made more efficient.
  • If the institutional buyer was looking to buy for the long term, I see no problem here. Their primary goal was always to profit from the Z-Y margin and if they managed to purchase at something less than Y, that was just gravy.
  • If they were only intending to hold on to the shares for a couple of seconds anyway because they were trying to do exactly the same thing to even slower and larger buyers up the food chain (i.e. they are only interested in the Y-X margin), then frankly, they had it coming and the world should not feel sorry for them.
  • On the face of it, it seems to me that institutional players complaining about HFT outfits doing front-running amounts to complaining that they’re being forced to do their real job (of actually analysing the long-term profitability of a business) instead of just day trading.
  • Other aspects of HFT, like quote stuffing, may still be harmful; I don’t know.
  • I can see why regular, retail day traders (i.e. guys sitting in their bedrooms) would hate HFT frontrunning: they’re the slowest form of momentum traders. I do not see why I should care about them.