QuantArb Engine: trading robot for Python
QuantArb Engine is an arbitrage advisor that profits from price dislocations between related instruments.
How the advisor works
The advisor tracks several related instruments and looks for the moment when their ratio deviates from the norm, allowing a chain of trades to be executed profitably without directional risk. Automation is mandatory: the window of opportunity lives fractions of a second.
Pure arbitrage on liquid markets has almost disappeared — dislocations are removed by high-frequency systems faster than a retail trader can react. The accessible variant is statistical arbitrage, but it carries the risk of the relationship between instruments breaking down.
Parameters and metrics
| Parameter | Value |
|---|---|
| Entry threshold | costs + 0.2 pip buffer |
| Execution latency | < 5 ms |
| Venues | 3 simultaneously |
| Language | Python + FIX API |
Why this advisor cannot be honestly tested on our data
An arbitrage engine holds a connection to several instruments at once and executes them synchronously — its entire logic is built on this. The MetaTrader tester runs an advisor on a single symbol, so reproducing a multi-symbol arbitrage position in it is technically impossible, and on the single EUR/USD pair there is nothing to build it from.
We deliberately do not show a backtest here: a tester report computed on unsuitable data would create a false impression of how the advisor behaves on a live account.
Pros and cons
- Profit is almost independent of market direction.
- Market-neutral while the instruments’ relationship holds.
- Based on a measurable dislocation.
- Pure arbitrage on liquid markets has practically disappeared.
- Requires several instruments and low latency.
- The statistical variant collapses when the relationship breaks.
Pitfalls
A statistical-arbitrage advisor is undone by the breakdown of the very relationship the strategy is built on: while the dependency holds, divergences revert and create false confidence, but on a structural shift the relationship breaks and both legs of the position take losses at once. The "market-neutral" robot turns out, at that moment, to be a directional bet.
Who it suits
For traders who understand the statistics of relationships between instruments and have infrastructure for simultaneous execution. Requires monitoring the stability of the relationship and readiness for its breakdown.
Related methodology
Frequently asked questions
Why is a standard tester unsuitable for an arbitrage advisor?
The MetaTrader tester works with one symbol per run, while an arbitrage engine holds several instruments at once and executes them synchronously. A multi-symbol position cannot be reproduced in a single-threaded tester.
Does risk-free arbitrage still exist?
On liquid markets it has practically disappeared: dislocations are removed in fractions of a second by high-frequency systems. A retail trader has access to statistical arbitrage, with the risk of the relationship breaking down.
What is the main risk of such an engine?
The breakdown of the relationship between instruments: the divergence stops reverting to the norm, and both legs of the position go into the red at once, despite the "neutrality".