Close the Skill Gap -> Enroll to be a Certified Financial Modeling & Valuation Analyst (FMVA)® Today!

Algorithms (Algos)

Algorithmic trading and the Bridgewater Hedge Fund

What are Algorithms (Algos)?

Algorithms (Algos) are a set of instructions that are introduced to carry out a specific task. Algorithms are introduced to automate trading to generate profits at a frequency impossible to a human trader. The process is referred to as algorithmic trading, and it sets rules based on pricing, quantity, timing, and other mathematical models. Other variations of algorithmic trading include automated trading and black-box trading.

Algorithmic trading rules out the human (emotional) impact on trading activities. The use of sophisticated algorithms is common among institutional investors like investment banks, pension funds and hedge funds due to the large volumes of shares that they trade daily. This allows them to get the best possible price at minimal costs and without significantly affecting the stock price.

 

algorithms, algos and algorithmic trading

 

Strategies for Algorithmic Trading

Any good strategy for algorithm trading must aim to improve trading revenues and cut costs of trading. The most popular strategies are arbitrage, index fund rebalancing, mean reversion, and market timing. Other strategies are scalping, transaction cost reduction, and pairs trading.`

 

Index Fund Rebalancing

The portfolios of index funds of mutual funds like individual retirement accounts and pension funds are regularly adjusted to reflect the new prices of the fund’s underlying assets. The “rebalancing” creates opportunities for algorithmic traders who capitalize on the expected trades depending on the number of stocks in the index fund. The trades are performed by algorithmic trading systems to allow for best prices, low costs, and timely results.

 

Algos and Arbitrage

Arbitrage is the practice of taking advantage of occasional small market price discrepancies that arise in the market price of a security that is traded on two different exchanges. Purchasing a dual-listed stock at a discount in Market A and selling it at a premium in Market B offers a risk-free arbitrage opportunity to profit. The practice can be applied in trading the S&P 500 futures contracts and S&P 500 stocks since it is common for slight price differentials to arise between the futures price and the total price of the actual underlying stocks. When it occurs, the securities trading on NASDAQ and NYSE either get ahead or lag behind the S&P futures traded in the CME market, creating an opportunity for arbitrage.

For arbitrage to occur, it must meet three conditions. First, the same assets should not trade at the same price on all markets. Second, two assets with the same cash flows should not trade at the same price. Lastly, an asset with a known price in the future should not trade today at the future price, discounted at the risk-free interest rate. Arbitrage is only possible with securities and financial products trading electronically. Also, the transactions should occur simultaneously to minimize the exposure to market risk or the probability that the price of one market may change before both transactions are complete.

 

Mean Reversion

Mean reversion is a mathematical method used in stock investing, and it computes the average of a stock’s temporary high and low prices. It involves identifying the trading range for a stock and calculating its average price using analytical techniques. When the current market price lags behind the average price, the stock is considered attractive, with the hope that the price will increase. On the other hand, when the current market prices go beyond the average price, the stock is considered undesirable as investors expect the price to fall, reverting back toward the average price. The standard deviation of the stock’s recent prices is often used as a buy or sell indicator.  Trading around mean reversion is a common use of algos.

 

Market Timing

Strategies that are designed to generate alpha are considered market timing strategies, and they use a method that includes live testing, backtesting, and forward testing. Backtesting is the first stage of market timing, and it involves simulating hypothetical trades through an in-sample data period. The next step is to perform optimization to get the most optimal results. The second stage of market timing is forward testing, and it involves running the algorithms throug sample data to ensure it performs within the backtested expectations. The last stage is live testing, and it requires a developer to compare live trades with the backtested and forward tested models.

 

Benefits of Algorithmic Trading

There are various advantages of allowing a computer to monitor and execute the live trades. One of the benefits of algorithm trading is the ability to minimize emotions throughout the trading process since trades are limited to a set of predefined instructions. Human trading is susceptible to emotions like fear and greed that may lead to poor decision-making. Through automated trading, traders have an easy time sticking to the plan. Automating the process also helps curb overtrading where some traders may buy and sell at every opportunity they get, and reduces chances of human-induced errors.

Trading with algorithms (Algos) also helps achieve consistency. The biggest challenge in the trading process is planning the trade and trading the plan. Failure to follow all the rules is likely to negatively alter any chance a trader has, even if the trading plan has the potential to be profitable. Although losses are part of trading, human traders may get discouraged after incurring two or more consecutive losses and fail to move to the next trade. By falling out midway through the process, the trader destroys any chances of winning in other rounds of trading. Automated trading helps to achieve consistency, trade according to the plan, and increase chances of winning.

In trading, every second counts and the speed of algorithmic trading makes it a favorable option for investing. Computers respond immediately to changing market conditions and can help generate orders as soon as the criteria are met, much faster than any person can recognize a change in the market and manually enter trading orders. Also, getting out or in too early or late can make a great difference in the day’s trading and automating the process helps cure the human-prone mistakes.

 

Disadvantages of Algorithmic Trading

Just like other mechanical processes, algorithmic trading is a sophisticated process, and it is prone to failures. Internet connectivity issues, power losses, and computer crashes can result in errant orders, duplicate orders and even missing orders that might not be sent to the market. Also, there could be a difference between the trades generated by the trading strategy and the actual results from the automated trading systems. Automated trading systems should be monitored at all times to prevent mechanical failures.

Traders who use backtesting techniques to optimize their systems may create systems that look good on paper but fail to perform in a live market. The problem may occur due to over-optimization, where traders create an excessive curve-fitting that produces a trading plan that is carefully fitted to previous market price behavior but unreliable in live, current markets. Some traders assume that a trading plan should have 100 percent profitable trades, without allowing room for drawdowns.

 

The Bridgewater Hedge Fund

Bridgewater Associates is the largest hedge fund in the world, with over $160 billion in assets under management. From a humble beginning, founder Ray Dalio built up a considerable fortune, but then nearly liquidated the firm after wrongly predicting a market downturn in 1982. Instead, the economy went the opposite way for a strongly bullish upswing. This failure, however, forced Ray Dalio to re-evaluate his thinking. From these events, he eventually developed the Pure Alpha fund strategy, which is largely an algo fund and is one of the main contributors to Bridgewater’s success. In fact, this strategy has worked so successfully that Dalio is now talking about developing an AI (artificial intelligence) program to run the company purely based off of the algorithmic methodologies employed by Pure Alpha.

 

Learn more about algos and trading:

  • Trading Floor
  • Trade Order Timing – Trading
  • Trade Orders – Trading
  • Trading Mechanisms – Trading

Corporate Finance Training

Advance your career in investment banking, private equity, FP&A, treasury, corporate development and other areas of corporate finance.

Enroll in CFI’s Finance Courses to take your career to the next level! Learn step-by-step from professional Wall Street instructors today.