Skip to content
All library documents

Adapting a Market Replay System to Forex Tick Data

Article MQL5 articles

Summary

This installment describes changes needed to adapt a MetaTrader 5 market replay system, originally built around Brazilian exchange data, to Forex. It contrasts exchange feeds that provide last-trade prices and volume with Forex data that may lack both and commonly charts bid prices; bid and ask may also coincide or vary in spread. These differences affect how tick files and one-minute bars should be interpreted, so the author focuses on replay rather than a full trade simulator.

The implementation raises custom-symbol precision to eight decimal places to accommodate Forex quotations and adds logic to infer the display mode from available tick fields, avoiding a manual market-type choice. It also adjusts timer behavior so replay can continue across long inactive periods while remaining responsive to chart closure and user interaction. The article says the system can replay attached Forex data but leaves configuration and other representation issues for later installments. It provides software adaptation guidance, not evidence about Forex strategy performance or a complete simulation model.

Key ideas

  • Forex feeds may omit last-trade price and volume, unlike the exchange data used by the original replay system.
  • Forex charts generally use bid prices, and bid-ask spreads can vary or sometimes be absent in the data.
  • The replay system detects market display mode from available tick fields rather than requiring user selection.
  • The author increases custom-symbol precision to support Forex quotations.
  • The installment adapts replay but postpones full simulation and acknowledges remaining configuration and data-representation issues.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.