Monitoring Tick Gaps with ATR Filtering and Shared Lag Alerts
Summary
The document describes an MQL5 utility for detecting unusually long intervals between incoming market ticks. It measures elapsed time between ticks and compares the gap with a configured threshold. An ATR-based volatility check can suppress alerts when wider tick spacing is consistent with elevated market volatility. The first tick initializes the timer rather than triggering an alert.
A timer checks whether a lag condition persists long enough to set a terminal-wide shared flag, allowing other Expert Advisors to respond. The class tracks which instance owns that flag and clears it when the lag ends; it also releases its indicator handle during cleanup. The document provides integration examples and lists configuration options and accessors. Its evidence consists of implementation behavior and example usage, not performance tests. It notes that ATR history or handle failures disable the volatility gate while leaving timing detection active. The monitor detects tick delays; it does not establish the cause of a delay or measure actual order execution quality.
Key ideas
- The monitor measures elapsed milliseconds between consecutive ticks and uses the first tick only to initialize timing.
- An ATR comparison can filter lag alerts during periods of elevated volatility.
- A timer confirms persistent lag and communicates it to other EAs through a terminal-wide variable.
- Shared-flag ownership and explicit cleanup are intended to prevent one instance from clearing another instance’s signal.
- The document describes implementation and integration, but provides no empirical validation of detection quality.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.