Most funded-account challenges fail on two rules traders rarely track side by side: peak-to-equity drawdown and single-day consistency caps. If a single winning session exceeds your prop firm consistency share (such as 30% of total net profit), payouts can be delayed or rejected even when equity stays positive.
PropFirm Consistency and Drawdown Monitor tracks daily drawdown, trailing total drawdown, and closed-bar consistency ratio in a lightweight chart HUD and exposes four iCustom buffers for automated Expert Advisors. Every ratio calculation guards denominators above 1e-9 and evaluates closed bars at shift >= 1 to prevent zero-divide faults and look-ahead bias.

Your EA reads closed-bar index InpClosedBarShift (default 1 , enforced >= 1 ) via CopyBuffer . Buffer 0 ( ExtStateBuf ) outputs monitor state ( 0 = OK, 1 = Warning at >=80% of any limit, 2 = Breach). Buffer 1 ( ExtDailyDdBuf ) outputs current daily drawdown percentage. Buffer 2 ( ExtTotalDdBuf ) outputs peak-to-equity total drawdown percentage. Buffer 3 ( ExtConsistencyBuf ) outputs the largest single-day profit share against total net profit (%).
int g_monitorHandle = INVALID_HANDLE;
int OnInit()
{
g_monitorHandle = iCustom(_Symbol, _Period, "PropFirm_Consistency_Drawdown_Monitor");
if(g_monitorHandle == INVALID_HANDLE)
return(INIT_FAILED);
return(INIT_SUCCEEDED);
}
bool IsRiskWithinLimits()
{
double stateBuf[1];
if(CopyBuffer(g_monitorHandle, 0, 1, 1, stateBuf) <= 0)
return(false);
return((int)MathRound(stateBuf[0]) < 2);
} | Parameter | Default | Description |
|---|---|---|
| InpInitialBalance | 100000.0 | Initial account balance in account currency used as peak equity floor. |
| InpMaxDailyDdPct | 5.0 | Maximum allowed daily drawdown percentage before flagging a breach. |
| InpMaxTotalDdPct | 10.0 | Maximum allowed overall peak-to-equity drawdown percentage. |
| InpConsistencyCapPct | 30.0 | Maximum allowed single-day profit share of total net profit (%). |
| InpClosedBarShift | 1 | Closed bar shift used for evaluation (enforced >= 1 to avoid look-ahead bias). |
| InpLookbackDays | 30 | Closed trade history lookback window in calendar days for daily profit aggregation. |
| InpPanelX | 20 | Top-right HUD horizontal offset in pixels. |
| InpPanelY | 20 | Top-right HUD vertical offset in pixels. |
| InpShowHud | true | Toggle read-only chart HUD panel visibility. |
This indicator focuses on live chart drawdown and consistency telemetry plus iCustom state output. It does not execute orders, close positions, replay historical M1 tick curves, or audit external HTML backtest reports. For setup notes and related risk utilities, visit the prop-firm risk guide or my MQL5 profile.
Breakout Follow-Through Statistics: Real Break or Fakeout After a New N-Bar High or Low?
Every new N-bar high or low gets tagged, timed, and scored — real breakout or fakeout — so the scorecard tells you what this symbol has actually done at its own extremes, not what you assume it does.
Pullback Depth Statistics: How Deep Do Pullbacks Go Before the Trend Resumes?
Builds a real depth distribution for this symbol's pullbacks — how far price typically retraces before the trend resumes, and how often it doesn't resume at all.
Accelerator Oscillator (AC)
The Acceleration/Deceleration Indicator (AC) measures acceleration and deceleration of the current driving force.
MACD Signals
Indicator edition for new platform.