What is Algorithmic Trading?

Algorithmic trading, or algo-trading, refers to trading which uses computer programming to place orders.

The trading is carried out on computers which are set up to follow an algorithm when placing trades. In other words, the computer follows a previously composed set of commands. These commands can be based on anything you want: price, quantity, timing, etc.

The advantages of algorithmic trading are numerous. The profit that this kind of trading makes and the speed and frequency that it does it in is incomparable to a human trader. Besides that, there’s no human emotion that can influence trading decisions, which makes the process more systematic. Also, the market is more liquid with algorithmic trading as well.algorithmic trading

Example: You want to set the following instructions – purchase 50 stock shares just after the 50-day moving average* surpasses the 200-day moving average. And you also want to sell stock shares when the 50-day moving average falls below the 200-day average.

*A moving average is a median of your previous data points which identifies trends by smoothing out regular, day-to-day movement of the price.

And now you can program the computer to follow these instructions. The program can control the stock price and moving averages. And not just that – the program can arrange buy and sell orders following your set of rules.

Now you don’t have to spend hours placing orders manually; you don’t even have to keep an eye on live graphs and prices. Algorithmic trading does it all for you. It sees the opportunity and doesn’t ever miss it.

In the rest of the article, we’ll address the many advantages of algo-trading, as well as some common strategies revolving it. Then we’ll also mention some of its technical requirements.

Algorithmic Trading Advantages

  • Algo-trading works with the best prices on the market.
  • Algo-trading’s order placement is accurate and fast. That’s why you can choose any level, and the computer will perform at that level successfully.
  • Algorithmic trades are perfectly timed, so it can avoid any possible price variations.
  • Algo-trading has discounted transaction costs.
  • With algo-trading, you can automatically check multiple market situations.
  • You can prevent any manually-made mistakes when placing orders.
  • You can backtest your trading strategy on both real-time and historical data that are available to you.
  • There’s no human psychological influence when it comes to trading decisions, so there is less chance of making a mistake, also.

Another key point is that high-frequency trading is the most used rendition of algorithmic trading today. What it does is follow the previously programmed instructions and place a multitude of orders at a fast speed, on multiple market conditions at the same time. The goal is to capitalize as much as possible.

Algorithmic trading is beneficial for various types of investing and trading. Here’s a few of them:

  • Mid-term to long-term investing and buy-side firms (insurance companies and pension funds). These investors can buy a huge number of stocks and not worry about their huge investments affecting the stock prices.
  • Sell-side participants and short-term traders. Speculators, market makers and arbitrageurs all profit from algorithmic trading and its automatic trading. Sellers also benefit from the market liquidity.
  • Systematic traders. Hedge funds, trend followers and pair traders** profit from algo-trading big time. By programming their own instructions and letting the computer trade automatically, they gain speed and efficiency.

** Pair trading is a trading strategy that is market-neutral. It uses a set of correlated instruments (two stocks, or ETFs, for example) and then matches a short position to a long position.

In short, algorithmic trading uses a more efficient trading approach and thus beats human trader’s methods that are based on sheer intuition.

The Strategies of Algorithmic Trading

We use strategies to recognize a profitable opportunity that will improve earnings or bring fewer costs.

These are the most popular strategies regarding algorithmic trading:

  • Trend-following strategies.

These strategies usually follow trends when it comes to price movements, average movements, channel breakouts, etc. Trend-following strategies are the simplest to program because there are no price predictions or forecasts involved. Predictions are way more difficult to implement. The trend-following strategy is pretty straightforward – trades are executed by following trends, which is basically the easiest instruction for an algorithm to pull off.

The previously mentioned example (with 200-day and 50-day moving averages) is a typical example of a trend-following strategy.

Arbitrage is the price difference when you are purchasing a dual stock in one market at a low cost and at the same time selling it in another market at a higher cost. You can do the same thing with stocks and futures instruments. Arbitrage is popular with algorithmic trading, as arranging the orders with it is much easier, and thus the effectiveness is much higher, too.Algorithmic Trading Math

  • Index fund rebalancing.

When it comes to index funds, there are rebalancing periods in order to match the holdings with their benchmark indices. When it comes to algorithmic traders, this is a great opportunity to capitalize. Right before index fund rebalancing, there are trades that offer anywhere from 20 up to 80 basis points (revolving around the quantity of stocks in the fund). We use algorithmic trading here to initiate trades at the best speed and price.

  • Mathematical models.

Mathematical models in algorithmic trading present a variety of options to choose from. An example of this is the delta-neutral strategy. This is a strategy that has many positions with negative and positive deltas. Delta is a ratio that shows the price variation of assets and compares it to the price variation in its derivative. In the end, the total delta of assets has to be zero.

  • Mean reversion.

Mean reversion (or trading range) strategy considers the fluctuation of prices as a temporary occurrence. Eventually, the price goes back to its mean (average). And then it will fluctuate again. That’s why it’s important to ascertain a price range. Then, after setting an algorithm, there can be an instruction for automatic order placement when the asset prices go beyond or below their price range.

  • Volume-weighted average price.

The VWAP strategy divides a big order into smaller parts by using historical volume profiles that are stock specific. The main goal of this strategy is to end up with a price that is similar to the VWAP.

  • Time-weighted average price.

The TWAP strategy also divides a big order into smaller parts. But with TWAP strategy, it uses evenly distributed time slots from the start to the end. The goal is to reduce the influence of the market and keep the price as similar as possible to the average cost, from the start to the end.

  • Percentage of volume.

This strategy includes an algorithm that sends partial orders based on the previously set participation ratio as well as the traded volume of the market. That occurs before the order is filled completely.

There’s another strategy related to this one – the ‘steps’ strategy. This strategy follows the percentage of volume that has been previously defined by users to send orders. And, once the stock price comes to the already set levels, it increases or decreases the participation rate.

  • Implementation shortfall.

The goal of this strategy is to reduce the order execution costs as much as possible. This can be done by trading in the real-time market. Doing so would certainly lead to fewer expenses in general. Not to mention the opportunity cost that comes with delayed execution. This strategy increases and decreases the participation rate based on the movement of the price and whether it’s favorable or not.

  • Other strategies and algorithms.

Besides the algorithms that we listed previously, which are all conventional, there are more than a few algorithms that work a bit differently. For example, there are ‘sniffing’ algorithms, which are set to detect algorithms that are found on the buy-side of large orders. These are mostly used by those who make the sell-side markets in order to help them recognize opportunities for large orders and thereby fill them at the highest price. This type of situation clearly shows the countless benefits of using technology and how using it can simply make you a front-runner.

Algorithmic Trading Technical Requirements

Actually integrating the algorithm into a computer is the very last step of the process, together with backtesting***. The real concern is how to convert the strategy you chose to a computerized process that can access a trading account and place orders.

*** Backtesting refers to the testing of an algorithm on past stock markets data. It should provide you with a clear picture of the algorithm’s performance, so you can know whether it’s actually profitable.

Firstly, here’s a list of things you need:

  • Programming skills, a hired professional programmer or a pre-made software that you can buy. Obviously, you need these in order to implement the algorithm into the computer.
  • Access to trading accounts (so you can place orders), and good internet connection
  • Market data feed access. The algorithm uses these to scout for order opportunities.
  • After you’re done computerizing the process, you need to test it.
  • Historical data. You need this for backtesting, as we mentioned earlier.

Example: RDS or Royal Dutch Shell is listed on both the London and the Amsterdam stock exchange market. Suppose you want to make an algorithm that will detect arbitrage opportunities.

Here’s where things get more complicated:

– Amsterdam stock exchange uses euros, whereas the London stock exchange trades in pounds.

– There’s an hour time difference; thus the Amsterdam exchange starts an hour before the London exchange. In the meantime, the trading happens at the same time in both exchange markets. But in the final hour, only the London market is trading.Algorithmic Trading Strategies

The question is: Is it possible to implement arbitrage trading on the RDS stock, but in different currencies?

The basic necessities for this kind of strategy are:

  • A program with the ability to interpret current market prices
  • Price feed for both the London and Amsterdam stock exchanges
  • A foreign exchange feed for the British pound and euro conversion
  • Ability to place orders to the proper exchange
  • And again, data for backtesting

The programmed computer has to be able to do this:

  • Read the Royal Dutch Shell stock incoming prices from both markets
  • Convert the prices (from pound to euro and vice versa) using the current exchange rates
  • Identify a good opportunity for placing orders (for instance, if there’s a large price difference).
  • When there’s an opportunity, place a buy order on the exchange with lower prices and place a sell order on the exchange with higher prices.

And finally, you have a program that will do all the work for you.

Although this may be true, don’t forget that there are other traders who are probably doing the same thing. So, in order to really shine, your strategy has to be better. That requires a lot of experience and knowledge. The program is there to simply make it easier for you.

Also, algorithmic trading isn’t all that easy to take up and manage. Even though the algorithm can work fast and seamlessly, you still need to keep an eye on it. Especially when it comes to price fluctuations.

In addition, there are risks, as with any other machine, too. For instance, a system failure or a connection problem can occur. And there’s always a chance that the algorithm was programmed poorly. If there’s a coding mistake, the program is basically useless.

Final Thoughts

A computerized trading process can certainly be effective. However, it has to be executed perfectly and tested many times. Only then can you use the program safely. But even after all that, you still have to monitor it for potential mistakes.