Algorithmic trading (automated trading, black-box trading or simply algo-trading) is the process of using computers programed to follow a defined set of instructions (an algorithm) for placing a trade in order to generate profits at a speed and frequency that is impossible for a human trader. The defined sets of rules are based on timing, price, quantity or any mathematical model. Apart from profit opportunities for the trader, algo-trading makes markets more liquid and makes trading more systematic by ruling out the impact of human emotions on trading activities.
Suppose a trader follows these simple trade criteria:
Using this set of two simple instructions, it is easy to write a computer program that will automatically monitor the stock price (and the moving average indicators) and place the buy and sell orders when the defined conditions are met. The trader no longer needs to keep watch for live prices and graphs, or put in the orders manually. The algorithmic trading system automatically does it for him, by correctly identifying the trading opportunity.
Algo-trading provides the following benefits:
The greatest portion of today’s algo-trading is high frequency trading (HFT), which attempts to capitalize on placing a large number of orders at very fast speeds across multiple markets and multiple decision parameters, based on preprogrammed instructions.
Algo-trading is used in many forms of trading and investment activities, including:
Algorithmic trading provides a more systematic approach to active trading than methods based on a human trader’s intuition or instinct.
Any strategy for algorithmic trading requires an identified opportunity that is profitable in terms of improved earnings or cost reduction. The following are common trading strategies used in algo-trading:
The most common algorithmic trading strategies follow trends in moving averages, channel breakouts, price level movements and related technical indicators. These are the easiest and simplest strategies to implement through algorithmic trading because these strategies do not involve making any predictions or price forecasts. Trades are initiated based on the occurrence of desirable trends, which are easy and straightforward to implement through algorithms without getting into the complexity of predictive analysis. The example mentioned above, of using the 50- and 200-day moving averages, is a popular trend-following strategy.
Buying a dual-listed stock at a lower price in one market and simultaneously selling it at a higher price in another market offers the price differential as risk-free profit or arbitrage. The same operation can be replicated for stocks vs. futures instruments, as price differentials do exist from time to time. Implementing an algorithm to identify such price differentials and placing the orders allows profitable opportunities in an efficient manner.
Index Fund Rebalancing
Index funds have defined periods of rebalancing to bring their holdings to par with their respective benchmark indices. This creates profitable opportunities for algorithmic traders, who capitalize on expected trades that offer 20 to 80 basis points profits depending on the number of stocks in the index fund, just before index fund rebalancing. Such trades are initiated via algorithmic trading systems for timely execution and best prices.
Mathematical Model Based Strategies
Proven mathematical models, like the delta-neutral trading strategy, allow trading on a combination of options and its underlying security. (Delta neutral is a portfolio strategy consisting of multiple positions with offsetting positive and negative deltas – a ratio comparing the change in the price of an asset, usually a marketable security, to the corresponding change in the price of its derivative – so that the overall delta of the assets in question totals zero.)
Trading Range (Mean Reversion)
Mean reversion strategy is based on the idea that the high and low prices of an asset are a temporary phenomenon that revert to their mean value (average value) periodically. Identifying and defining a price range and implementing an algorithm based on that allows trades to be placed automatically when the price of asset breaks in and out of its defined range.
Volume Weighted Average Price (VWAP)
Volume weighted average price strategy breaks up a large order and releases dynamically determined smaller chunks of the order to the market using stock-specific historical volume profiles. The aim is to execute the order close to the Volume Weighted Average Price (VWAP).
Time Weighted Average Price (TWAP)
Time weighted average price strategy breaks up a large order and releases dynamically determined smaller chunks of the order to the market using evenly divided time slots between a start and end time. The aim is to execute the order close to the average price between the start and end times, thereby minimizing market impact.
Percentage of Volume (POV)
Until the trade order is fully filled, this algorithm continues sending partial orders, according to the defined participation ratio and according to the volume traded in the markets. The related “steps strategy” sends orders at a user-defined percentage of market volumes and increases or decreases this participation rate when the stock price reaches user-defined levels.
The implementation shortfall strategy aims at minimizing the execution cost of an order by trading off the real-time market, thereby saving on the cost of the order and benefiting from the opportunity cost of delayed execution. The strategy will increase the targeted participation rate when the stock price moves favorably and decrease it when the stock price moves adversely.
Beyond the Usual Trading Algorithms
There are a few special classes of algorithms that attempt to identify “happenings” on the other side. These “sniffing algorithms” – used, for example, by a sell-side market maker – have the in-built intelligence to identify the existence of any algorithms on the buy side of a large order. Such detection through algorithms will help the market maker identify large order opportunities and enable them to benefit by filling the orders at a higher price. This is sometimes identified as high-tech front-running.
Implementing the algorithm using a computer program is the last part, accompanied by backtesting (trying out the algorithm on historical periods of past stock-market performance to see if using it would have been profitable). The challenge is to transform the identified strategy into an integrated computerized process that has access to a trading account for placing orders. The following are needed:
Here is an example of how algorithmic trading works: Royal Dutch Shell (RDS) is listed on Amsterdam Stock Exchange (AEX) and London Stock Exchange (LSE). We start by building an algorithm to identify arbitrage opportunities. Here are few interesting observations:
Can we explore the possibility of arbitrage trading on the Royal Dutch Shell stock listed on these two markets in two different currencies?
The computer program should perform the following:
Simple and easy! However, the practice of algorithmic trading is not that simple to maintain and execute. Remember, if you can place an algo-generated trade, so can the other market participants. Consequently, prices fluctuate in milli- and even microseconds. In the above example, what happens if your buy trade gets executed, but the sell trade doesn’t because the sell prices change by the time your order hits the market? You will end up sitting with an open position, making your arbitrage strategy worthless.
There are additional risks and challenges: For example, system failure risks, network connectivity errors, time-lags between trade orders and execution, and, most important of all, imperfect algorithms. The more complex an algorithm, the more stringent backtesting is needed before it is put into action.
It’s exciting to go for automation aided by computers with the goal of making money effortlessly. But one must make sure the system is thoroughly tested and required limits are set. Analytical traders should consider learning programming and building systems on their own, to be confident about implementing the right strategies in a foolproof manner. Cautious use and thorough testing of algo-trading can create profitable opportunities.