Skip to content

fix: minImBalanced and tolerance are raw points — document per-symbol calibration #65

Description

@cfournel

Problem

minImBalanced (FVG size threshold) and tolerance (liquidity sweep tolerance) are compared in raw MT5 points after dividing by _Point. While these happen to be roughly consistent in pip terms across standard symbols (50 points ≈ 5 pips), they are not explicitly documented as pip-based and may cause confusion when calibrating new symbols.

Code locations:

  • cOrderBlock.mqh:1044-1068: imbalancedDist = MathAbs(low - high) / SYMBOL_POINT vs minImBalanced
  • cOrderBlock.mqh:1117-1143: distance = MathAbs(BSL.price - HighLevel) / _Point vs tolerance

Current defaults: minImBalanced=40, tolerance=50 (raw points)

Equivalents across symbols

Symbol Digits 50 points = Notes
XAUUSD 2 $0.50 / 5 pips Reasonable
EURUSD 5 0.5 pips Very tight
USDJPY 3 0.5 pips Very tight
USDX 3 $0.05 / 0.5 pips Very tight

Recommendation

  1. Add comments to inputs.mqh clarifying these are in MT5 points (not pips, not price units)
  2. Document per-symbol calibration in CLAUDE.md
  3. Consider exposing a tolerance_pips input normalized the same way as the ATR fix (fix: normalize ATR_max/ATR_min to pips — currently broken for all non-XAUUSD symbols #64) in a future refactor

Related

Metadata

Metadata

Assignees

Labels

documentationImprovements or additions to documentation

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions