Skip to content
All library documents

Automating Bat Harmonic Pattern Detection and Trading in MQL5

Article MQL5 articles

Summary

The article describes an MQL5 system for identifying bullish and bearish Bat harmonic patterns from five swing points, labeled X, A, B, C, and D. It defines the pattern through their sequence and Fibonacci relationships: B retraces about half of XA, C retraces a specified portion of AB, and D reaches 0.886 of XA. Pivot settings and a tolerance parameter govern pattern detection.

When a pattern is confirmed, the system can draw its points and connecting lines on a chart and place a trade with an entry, stop loss, and staged take-profit levels. The article reports that it includes a backtest graph and report, but provides no readable performance figures or evaluation details in the supplied text. Pivot confirmation can delay recognition, and the article presents the strategy as customizable and educational; it does not establish that the pattern reliably predicts reversals or will perform across markets.

Key ideas

  • A Bat pattern is defined by five ordered swing points and Fibonacci relationships between its legs.
  • The system detects both bullish and bearish forms using pivot points and a configurable tolerance.
  • Confirmed patterns can be drawn on the chart and used to set entries, stops, and multiple profit targets.
  • The article mentions backtesting but supplies no interpretable performance figures in the text provided.
  • Pattern recognition alone does not establish future performance, so the strategy needs independent validation.

Tags

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