Faithful statement of the open-source MQL5 expert advisor '3MAF' v1.5 by geraked (MIT licence, https://github.com/geraked/metatrader5/blob/d3eb29c382acf715727d5cd6a0414151e821fc2d/Experts/3MAF.mq5, plus the order/trail/grid helpers it calls in Include/EAUtils.mqh at the same commit). All credit for the strategy goes to the author. The original was published for USDCAD 15M (2021-02 to 2023-09). Any performance it claims is unverified; our backtest with real Bybit fees decides. It is a real tradeable strategy, not a utility.
PLATFORM MAPPING. Instrument ETHUSDT.BYBIT, Bybit linear USDT perp, 15-MINUTE bars. It has multi-year 15m history in the catalog from 2021-03-15; the OKX alt 15m series only holds about 2 days. Venue fees are 0.02% maker and 0.055% taker, about 0.11% round trip. The strategy needs shorts and leverage, so it cannot run on spot. The mechanism is pure OHLCV, so BYBIT is admissible (lesson L160). BTC was avoided because of corpus concentration. Config leverage is 10.0 and acts as the margin ceiling that stands in for MT5's broker margin. News filter, spread limit and equity-drawdown limit are all OFF by default in the source, so they are omitted.
INDICATORS (defaults exactly as written):
- MA1 = EMA(close, 60), MA2 = EMA(close, 350), MA3 = EMA(close, 600). MaMethod is MODE_EMA and MaPrice is PRICE_CLOSE.
- Williams Fractals, as in MT5's built-in iFractals. A lower fractal at bar j means low[j] < low[j+1] and low[j] < low[j+2] (the two newer bars), and low[j] <= low[j-1] and low[j] <= low[j-2] (the two older bars). The upper fractal mirrors this with highs.
- The EA evaluates on the first tick of a new bar and reads fractal buffer index 2. That is the bar before the just-closed bar, and its 'second newer bar' is the new bar that has only its opening tick.
- Point-in-time translation at the close of our bar t (MQL index 1 = t, index 2 = t-1): a lower fractal at t-1 requires low[t-1] < low[t] AND low[t-1] < close[t] (close[t] stands in for the new bar's open on a 24/7 market), AND low[t-1] <= low[t-2] AND low[t-1] <= low[t-3]. The upper fractal at t-1 mirrors this with highs.
- Warm-up is 600 bars before any signal.
The EA is evaluated once per closed bar. Trail and grid management runs on the source's 60-second timer. We run it once per closed 15m bar and rest stop/limit orders at the computed levels, so intrabar touches fill.