0
Exchange Simulators for SOR / Algo Testing: Advantages vs. Shortcomings Alexey Zverev, Alyona Bulda Exactpro Systems LLC
SOR & Other Trading Algorithms <ul><ul><li>Introduction </li></ul></ul><ul><ul><li>Examples </li></ul></ul><ul><ul><ul><li...
SOR & Other Trading Algorithms Abstract Scheme
Testing of SOR & Trading Algorithms <ul><ul><li>SOR or Algo Trading systems: </li></ul></ul><ul><ul><li>  </li></ul></ul><...
Testing of SOR & Trading Algorithms <ul><ul><li>System Testing </li></ul></ul><ul><ul><ul><li>Algo developers need an abil...
Testing of Trading Systems Connected to Electronic Markets <ul><ul><li>All electronic markets provide test environments wh...
Testing of Trading Systems Connected to Electronic Markets <ul><ul><li>Trading system connectivity layer usually has a spe...
Exchange Simulators: Their Role & Species <ul><ul><li>Exchange Simulators is something that simulates the market in order ...
SOR & Other Trading   Algorithms vs. Exchange Simulators: Abstract Scheme
The Advantages of Using Exchange Simulators <ul><ul><li>Exchange Simulators: </li></ul></ul><ul><ul><ul><li>Provide more c...
The Shortcomings of Using Exchange Simulators, API Emulation <ul><ul><li>An Exchange is a complex proprietary black box sy...
The Shortcomings of Using Exchange Simulators, API Emulation <ul><ul><li>Real life examples: </li></ul></ul><ul><ul><ul><l...
The Shortcomings of Using Exchange Simulators, Market Simulation <ul><ul><li>It is impossible to develop a Market Model, o...
The Shortcomings of Using Exchange Simulators, Market Simulation <ul><li>Real life example: the Exactpro Exchange Simulato...
The Shortcomings of Using Exchange Simulators, Market Simulation <ul><ul><li>Exchange Simulator Design: </li></ul></ul><ul...
Upcoming SlideShare
Loading in...5
×

Exchange Simulators for SOR / Algo Testing: Advantages vs. Shortcomings

1,326

Published on

The Advantages of Exchange Simulators in Algo Trading Systems Testing
Alexey Zverev, Managing Director Exactpro Systems, Head of CFT QA

The Shortcomings of Exchange Simulators
Alyona Bulda, ClubQA Co-Founder, Kostroma

EXTENT Conference
October 29-30, 2011
Test Automation for Trading Systems

Published in: Business, Economy & Finance
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,326
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
15
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Transcript of "Exchange Simulators for SOR / Algo Testing: Advantages vs. Shortcomings"

  1. 1. Exchange Simulators for SOR / Algo Testing: Advantages vs. Shortcomings Alexey Zverev, Alyona Bulda Exactpro Systems LLC
  2. 2. SOR & Other Trading Algorithms <ul><ul><li>Introduction </li></ul></ul><ul><ul><li>Examples </li></ul></ul><ul><ul><ul><li>Quoting and Market Making </li></ul></ul></ul><ul><ul><ul><li>Executing substantial orders automatically </li></ul></ul></ul><ul><ul><ul><li>Smart Order Routing </li></ul></ul></ul><ul><ul><ul><li>Arbitrage </li></ul></ul></ul>
  3. 3. SOR & Other Trading Algorithms Abstract Scheme
  4. 4. Testing of SOR & Trading Algorithms <ul><ul><li>SOR or Algo Trading systems: </li></ul></ul><ul><ul><li>  </li></ul></ul><ul><ul><ul><li>Trade automatically </li></ul></ul></ul><ul><ul><ul><li>May or may not receive external instructions (parent orders) </li></ul></ul></ul><ul><ul><ul><li>Connects to one or multiple execution venues (markets, exchanges) </li></ul></ul></ul><ul><ul><ul><li>Connects to low latency Market Data Source to receive current prices </li></ul></ul></ul><ul><ul><ul><li>Makes a decision based on market data and statuses of the orders sent to the external markets.  </li></ul></ul></ul>
  5. 5. Testing of SOR & Trading Algorithms <ul><ul><li>System Testing </li></ul></ul><ul><ul><ul><li>Algo developers need an ability to verify the correctness of algorithm implementation within the trading platform </li></ul></ul></ul><ul><ul><ul><li>Testing of surrounding infrastructure (module testing) </li></ul></ul></ul><ul><ul><ul><ul><li>Example order should be delivered correctly between algo and Market </li></ul></ul></ul></ul><ul><ul><li>Algo Performance Testing / Back testing </li></ul></ul><ul><ul><ul><li>Analysts need an ability to test the algorithm profitability </li></ul></ul></ul><ul><ul><ul><ul><li>This is usually done via back testing (applying algo to historical data) or applying algo against some model simulating market behavior or combination of these approaches </li></ul></ul></ul></ul>
  6. 6. Testing of Trading Systems Connected to Electronic Markets <ul><ul><li>All electronic markets provide test environments where clients are able to test their connectivity. These environments are supposed to be identical to production environment. </li></ul></ul><ul><ul><li>Alternative to testing against such test environment is using a Test Harness.  </li></ul></ul>
  7. 7. Testing of Trading Systems Connected to Electronic Markets <ul><ul><li>Trading system connectivity layer usually has a specific layer isolating other components from the specific Market API implementation </li></ul></ul><ul><ul><li>Exchange Emulator can either emulate a specific API or an intermediate component. This way we can reduce the amount of API development work for our Test Harness </li></ul></ul>
  8. 8. Exchange Simulators: Their Role & Species <ul><ul><li>Exchange Simulators is something that simulates the market in order to test trading systems </li></ul></ul><ul><ul><li>  There are two types Exchange Simulators: </li></ul></ul><ul><ul><ul><li>API Emulators – they emulate exchange connectivity, provide scriptable responses and unsolicited events </li></ul></ul></ul><ul><ul><ul><li>Market Simulators – they simulate market/ multiple markets responses based on some model </li></ul></ul></ul><ul><ul><li>  The API emulator is used to emulate external exchange connection in a controlled manner </li></ul></ul><ul><ul><li>The Market Simulator is for testing algorithms via exchange simulations or historical market data replay (back testing) </li></ul></ul>
  9. 9. SOR & Other Trading Algorithms vs. Exchange Simulators: Abstract Scheme
  10. 10. The Advantages of Using Exchange Simulators <ul><ul><li>Exchange Simulators: </li></ul></ul><ul><ul><ul><li>Provide more control over testing </li></ul></ul></ul><ul><ul><ul><li>Enhance the ability to emulate various events to increase test coverage </li></ul></ul></ul><ul><ul><ul><li>Provide the ability to test the algo incorporated into the real production software (not in Excel or Matlab) </li></ul></ul></ul><ul><ul><ul><li>  ... under the real load mimic the real production environments  </li></ul></ul></ul>
  11. 11. The Shortcomings of Using Exchange Simulators, API Emulation <ul><ul><li>An Exchange is a complex proprietary black box system. Its nearly impossible to emulate its API behavior accurately </li></ul></ul><ul><ul><li>  This black box constantly changes </li></ul></ul><ul><ul><li>Algo Trading Systems usually have to deal with multiple Exchanges </li></ul></ul><ul><ul><li>In a High Frequency Trading network, delays and hardware issues matter. This cannot be simulated  </li></ul></ul><ul><ul><li>The certification by the Exchanges of the Gateways connecting to the Exchanges should happen in Exchange Test Connection, so API emulator development is duplication of effort  </li></ul></ul>
  12. 12. The Shortcomings of Using Exchange Simulators, API Emulation <ul><ul><li>Real life examples: </li></ul></ul><ul><ul><ul><li>  The other side of the barricade is supporting client certification of a trading venue. The following issues could be discovered only via the certification process: </li></ul></ul></ul><ul><ul><ul><ul><ul><li>Missing Execution Reports recovery through resend request mechanism </li></ul></ul></ul></ul></ul><ul><ul><ul><ul><ul><li>XML instrument definition distribution </li></ul></ul></ul></ul></ul><ul><ul><ul><ul><ul><li>Exotic multi-leg trades  </li></ul></ul></ul></ul></ul><ul><ul><ul><ul><ul><li>Runtime instrument creation </li></ul></ul></ul></ul></ul><ul><ul><ul><ul><ul><li>Implied liquidity dissemination </li></ul></ul></ul></ul></ul>
  13. 13. The Shortcomings of Using Exchange Simulators, Market Simulation <ul><ul><li>It is impossible to develop a Market Model, only some localized bits and pieces </li></ul></ul><ul><ul><li>The Market Model is a valuable intellectual property of buy side players. Information is not available for public research </li></ul></ul><ul><ul><li>Requires a lot of real trading / HFT experience to be able to come up with it </li></ul></ul><ul><ul><li>An Exchange Simulator must be really flexible in terms of its model </li></ul></ul><ul><ul><li>Dark/Hidden Liquidity Markets are impossible to analyze and predict </li></ul></ul><ul><ul><li>The Development of such a system requires a tremendous effort in terms of development and financial math resources and costs a lot; and anyway is far worse than the real market in terms of the development of real Algos </li></ul></ul>
  14. 14. The Shortcomings of Using Exchange Simulators, Market Simulation <ul><li>Real life example: the Exactpro Exchange Simulator </li></ul>
  15. 15. The Shortcomings of Using Exchange Simulators, Market Simulation <ul><ul><li>Exchange Simulator Design: </li></ul></ul><ul><ul><ul><li>  Order Book exactly replicating all exchange rules </li></ul></ul></ul><ul><ul><ul><ul><li>This is already a challenge – real life example </li></ul></ul></ul></ul><ul><ul><ul><li>Trading Systems connect to the simulator as if they are connecting to the real exchange (both for OE and MD) </li></ul></ul></ul><ul><ul><ul><ul><li>Need to support adequate load generated by Trading Algos </li></ul></ul></ul></ul><ul><ul><ul><li>Market Model is implemented in three instances: </li></ul></ul></ul><ul><ul><ul><ul><li>The system is fed with historical orders recreating historical order books  </li></ul></ul></ul></ul><ul><ul><ul><ul><li>A bunch of competing strategies representing the real market </li></ul></ul></ul></ul><ul><ul><ul><ul><li>Counter flow model constantly monitors the liquidity on the book and generates artificial events to simulate market impact of orders generated by the Trading System under test </li></ul></ul></ul></ul>
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×