HomeBlogsBetter testing for trading algos

Better testing for trading algos

Everybody is familiar with the now-infamous “flash crash” of 6 May 2010, in which US markets dropped nearly 10% before recovering almost immediately. The reality is that these “flash crashes” happen all the time in markets worldwide. However, they’re not as large as the May 2010 occurrence and therefore not so noteworthy.

It’s widely suspected that one or more High Frequency Trading (HFT) algorithms cause these flash crashes, for one of two reasons:

  1. The algorithm is fundamentally flawed in its own right
  2. One or more algorithms, while independently sound, malfunction and misbehave when interacting with other algorithms and/or with normal market activity

Algorithms execute trades automatically without human intervention. HFT firms use them along with ultra-fast, ultra-low latency connections to generate returns by rapidly selling or buying securities multiple times in a narrow window of time – often tiny fractions of a second.

That’s not to say that algorithms are only used for high frequency trading. Firms also devise algorithms that automatically buy, sell or switch securities when particular market conditions occur that might only happen once a month, quarter or year. For example, a trading firm can write an algorithm that sells an entire portfolio when the FTSE 100 hits 7000. This doesn’t need to be a high frequency trade – and in fact probably couldn’t be, since a portfolio sell-out could still take seconds to place electronically.

Unsurprisingly, the European Commission’s new and wide-ranging MiFID II regulations, which are due to go live in early 2017, seek to address concerns around algorithms’ ability to damage and disrupt trading markets.

Firstly, MiFID II stipulates that any firm that uses any algorithms (not just high-frequency ones) must carry out its own testing to prove to the regulator that its algorithms won’t disrupt a market, and also won’t malfunction under stress conditions.

Secondly, exchanges and other trading venues must provide facilities in which algo trading firms using the venue can “stress test” their algorithm’s performance against the market and other algorithms in an environment that simulates live trading conditions. This is critical since an algorithm that passes independent testing on its own, in isolation, might still malfunction or interact badly with other (simulated) algorithms or other trading activity in a live simulation. Market watchers believe that algorithms that had reportedly functioned correctly in isolation testing interacted badly with one other when released into the real market, causing the May 2010 flash crash.

Algo trading firms will need to submit their algorithms to this testing on an annual basis, and also whenever they make “significant” changes to an algorithm’s workings.

HFTs already test their algorithms regularly, replaying them against banks of historical data in order to re-calibrate and fine tune particular parameters or code. The MiFID II requirements will require them to demonstrate that they’ve carried out the new testing obligations, both independently and in conjunction with the relevant venue in a simulation of live market conditions. Non-HFTs who operate algorithms will also have to adhere to these obligations.

The EU is not the only region taking action to regulate algo trading. In the USA, market governing bodies are putting in place similar regulations for algo trading – although their legislation might not go as far as the European version. We’re unlikely, however, to see much algo regulation in Asia Pacific, since cross-market opportunities in APAC are much more limited. Nor is there an established pan-regional political union in Asia that’s the equivalent of the EU and which can enact legislation on market players.

The practical solution for algorithm operators – both HFT and non-HFT – is to access and use independent test environments that simulate live market conditions.

Here at Colt, we announced earlier this month that TraderServe, a software and appliance vendor and consultancy firm, had joined PrizmNet, Colt’s financial services extranet that connects providers of financial content to Capital Markets firms. TraderServe will provide access via PrizmNet to Algoguard, its algorithm testing and validation engine. AlgoGuard will be available to all Capital Markets participants – wherever they are in the world – who require the ability to demonstrate compliance for algorithm testing under MiFID II.

By following a course of regular active testing, HFTs can demonstrate independence and auditability to the regulators; and also adjust and make necessary changes to their algos at very short notice.

What's your goal today?

1. Are you on the Colt IQ network?

Our network connects over 31,000 buildings worldwide powering companies such as Hitachi, Atos, Forbes, Arthur D Little, Brussels Airlines and thousands of others. Find out if you're Colt connected now.

2. Learn about digital infrastructure

We've written thousands of guides and white papers, regularly publish content on our blog and host regular events on everything from enterprise network connectivity, to cloud, digital transformation and the hybrid workforce.

3. Join our team

To learn more about joining our team of over 5000 people around the world, and to browse our current open roles visit https://careers.colt.net/.