Tarea técnica
Title: MQL5 EA Developer Needed — EUR/USD 15M Scalping Robot (1:1 RR, Rule-Based)
Platform: MetaTrader 5 (MQL5)
Description:
Looking for an experienced MQL5 developer to build a fully automated Expert Advisor for EUR/USD on the 15-minute timeframe. The strategy is a rule-based pullback scalp system with a fixed 1:1 risk/reward ratio, EMA-based trend filtering, session-time restrictions (London open + London/NY overlap only), news blackout windows, and strict risk controls (per-trade risk %, daily loss limit, daily trade cap, consecutive-loss cooldown).
The full entry/exit logic, indicator setup, position sizing formula, all adjustable input parameters, and required backtest deliverables are documented in the attached spec. This is an implementation job — the strategy design is complete, no discretionary strategy input needed from the developer.
Scope of work:
- Build the EA to the attached specification exactly — flag any ambiguities or judgment calls before coding rather than assuming
- Deliver compiled EA (.ex5) + full commented source code
- Run backtests per the spec's requirements: minimum 3-5 years of M15 tick data, realistic spread/commission/slippage modeling, walk-forward validation (in-sample/out-of-sample split), and a 2x-spread/slippage stress test
- Deliver the backtest report with all required metrics (win rate vs breakeven-win-rate-needed, profit factor, drawdown, Sharpe/Sortino, per-session breakdown, etc. — full list inspec)
- Written summary of any deviations from spec, with rationale
Requirements:
- Proven MQL5 experience — please share 2-3 past EA samples or portfolio links
- Comfortable with ATR-based position sizing, session/time-window filters, and proper walk-forward backtesting methodology (not just a single in-sample optimization)
- Understands why cost modeling (spread/slippage) is critical for a tight-stop scalping system, not an afterthought
Deliverables:
- Compiled .ex5 file
- Full commented source (.mq5)
- Backtest report (HTML/PDF export from Strategy Tester)
- Written assumptions/deviations summary
Budget/Timeline: reasonable price please
***************PLEASE SEE SCOPE WORKS BELOW************
EA Development Spec: EUR/USD 15M 1:1 RR Pullback Scalp SystemOverview
A session-filtered mean-reversion pullback scalp on EUR/USD, 15-minute timeframe, trading with a strict 1:1 risk/reward ratio (target distance = stop distance, no exceptions). Trend direction is set by a dual-EMA filter; entries are taken on pullbacks to a fast EMA within that trend, confirmed by a rejection candle. Built for MQL4 or MQL5 (specify platform — MT4 or MT5).
Critical note for the developer: because R:R is fixed at 1:1, this system's entire edge must come from win rate. Breakeven before costs is 50%; on a 15M chart with typical stops of 10-20 pips, spread + slippage can consume 5-15% of the risk unit, pushing the real breakeven win rate to roughly 55-58%. The backtest (Section 9) exists specifically to prove or disprove that this setup clears that bar — do not treat the entry logic below as validated until it does.
1. Indicators Required
| Indicator | Parameters | Purpose |
|---|---|---|
| EMA (slow) | Period 200, Close, 15M | Trend/regime filter |
| EMA (medium) | Period 50, Close, 15M | Trend/regime filter (confirms EMA200 direction) |
| EMA (fast) | Period 20, Close, 15M | Pullback reference level |
| ATR | Period 14, 15M | Stop-loss sizing (and therefore target sizing, since RR=1:1) |
2. Session Filter (Applies Before Any Entry Logic)
Trading is only permitted inside these windows (server/broker time must be mapped to EST — confirm broker GMT offset and DST handling explicitly with developer):
- London open: 3:00 AM–5:00 AM EST
- London/NY overlap: 8:00 AM–11:00 AM EST
Outside these windows: no new entries, regardless of setup quality.
News blackout: No new entries within 15 minutes before or after scheduled high-impact USD or EUR news (NFP, CPI, FOMC rate decisions/statements, ECB rate decisions). Developer should integrate an economic calendar feed (or accept a manually maintained blackout list as a fallback input) — flag which approach is used.
3. Entry Logic
Trend condition (must hold for both directions):
- Long bias: Close > EMA50 > EMA200 (aligned uptrend, not just price above one average)
- Short bias: Close < EMA50 < EMA200 (aligned downtrend)
Long entry, all conditions true:
- Long bias trend condition holds
- Price pulls back and touches or crosses the 20 EMA (wick or close within 1 pip of the EMA)
- A rejection candle forms at/near the EMA: candle has a lower wick ≥ 40% of its total range, and closes in the upper half of its range, back in the direction of the trend
- Entry triggers on a stop order at the rejection candle's high + 1 pip, active for the next 1 candle only (cancel if not filled)
- Inside an active session window (Section 2), no active news blackout
- No existing open position on EUR/USD from this EA
Short entry, mirror conditions:
- Short bias trend condition holds
- Price pulls back and touches or crosses the 20 EMA
- Rejection candle: upper wick ≥ 40% of range, closes in lower half of range
- Entry triggers on a stop order at the rejection candle's low − 1 pip, active for next 1 candle only
- Inside an active session window, no active news blackout
- No existing open position
4. Exit Logic (Fixed 1:1 — No Discretion)
Stop-loss:
- Placed beyond the rejection candle's wick extreme (long: below the low; short: above the high), with a minimum floor of 1.0×ATR(14) and a maximum cap of 1.5×ATR(14) — if the wick-based distance falls outside this band, skip the trade rather than override it (log as "skipped: stop out of ATR band").
Take-profit:
- Exactly equal to the stop-loss distance from entry (1:1). No trailing stop, no partial close, no discretionary management. This is what keeps the system statistically a 1:1 scalp rather than a disguised trend trade.
Time stop:
- If neither SL nor TP is hit within 8 bars (2 hours on 15M) of entry, close at market. Log as "time stop" separately from SL/TP hits so win-rate stats aren't distorted by open-ended trades.
No re-entry same setup: if stopped out, do not re-enter on the same EMA touch/rejection sequence — wait for a new pullback cycle (price must move away from and back to the 20 EMA).
5. Position Sizing
- Risk per trade: 0.5% of account equity (adjustable, InpRiskPercent )
- Formula: LotSize = (AccountEquity × RiskPercent) / (StopDistanceInPips × PipValuePerLot)
- Round down to broker's minimum lot step; reject and log if below broker minimum.
6. Portfolio-Level Risk Controls
- Max 1 concurrent open position on EUR/USD for this EA.
- Daily loss circuit breaker: realized loss ≥ 3% of starting daily equity → disable new entries until next trading day.
- Daily trade cap: max 6 new entries per day (scalping systems can over-trade in choppy conditions; this caps damage from a bad regime day). Adjustable, InpMaxTradesPerDay .
- Consecutive loss cooldown: after 3 consecutive losing trades, pause new entries for the remainder of the current session window. Adjustable, InpConsecLossPause .
- No martingale, no grid, no averaging into losing positions.
7. Inputs (Adjustable Parameters)
InpEMAFast = 20 InpEMAMedium = 50 InpEMASlow = 200 InpATRPeriod = 14 InpStopATRMin = 1.0 InpStopATRMax = 1.5 InpTimeStopBars = 8 InpRiskPercent = 0.5 InpDailyLossLimit = 3.0 // percent InpMaxTradesPerDay = 6 InpConsecLossPause = 3 InpSession1Start = "03:00" // EST InpSession1End = "05:00" InpSession2Start = "08:00" InpSession2End = "11:00" InpNewsBlackoutMins = 15 InpMagicNumber = [assign unique number] InpMaxSlippagePips = 1
8. Logging Requirements
Every trade must log (to file and/or terminal):
- Entry time, price, direction, ATR at entry, stop distance (pips), lot size
- Exit time, price, exit reason (take-profit / stop-loss / time-stop)
- Realized P&L in account currency and in R-multiples (should cluster at +1R/-1R, with time-stops as the only variable-R outcomes)
- Trades skipped due to stop-out-of-ATR-band, daily trade cap, consecutive loss pause, or news blackout — with reason
- Daily/weekly circuit breaker triggers
9. Backtest Requirements (Required Before Any Live/Demo Deployment)
9.1 Data
- Instrument: EUR/USD
- Timeframe: 15M (M15)
- Period: Minimum 3 years, ideally 5, covering multiple volatility regimes and including at least one low-volatility grind period (this system is most exposed to chop/noise regimes, more so than the 4H trend system)
- Tick data quality: "Every tick based on real ticks" model required — for a 1:1 system with small stops, fill-price accuracy matters more than for wider-stop systems. Do not accept "open prices only" backtests as valid.
9.2 Cost Assumptions (Must Be Included, Not Added Later)
- Spread: minimum 1.2-1.5 pips, using variable/realistic spread modeling if the platform supports it — spread cost as a % of a ~10-20 pip stop is the single biggest threat to this system's viability and must not be underestimated
- Commission: model per actual broker's round-turn commission structure
- Slippage: 0.5-1 pip average on entry fills, up to 2 pips on stop/time-stop exits during session-open volatility spikes
9.3 Required Backtest Outputs
- Win rate — the single most important number for this system; report to one decimal place
- Net profit/loss (absolute and % return) over full period
- Breakeven win rate actually achieved vs breakeven win rate required after costs (developer should calculate and report both explicitly)
- Maximum drawdown (%) and max drawdown duration
- Sharpe and/or Sortino ratio
- Total trades, trades per week/month (confirms frequency given the session filter is restrictive)
- Profit factor
- Longest losing streak (count, and whether the consecutive-loss pause materially reduced drawdown vs a version without it — run both)
- Breakdown by session window (London-open vs overlap) — win rate may differ meaningfully between the two; report separately, not just pooled
- Equity curve chart and monthly returns heatmap
9.4 Walk-Forward Validation (Required)
- In-sample (70%) / out-of-sample (30%) split, chronological, no shuffling
- Any parameter tuning (EMA periods, ATR band, rejection-candle wick %) done only on in-sample data; out-of-sample run once, unmodified, as the real test
- A win rate that only clears breakeven in-sample and not out-of-sample means the setup is overfit and should not proceed
9.5 Stress Testing
- Re-run with spread widened 2x and slippage doubled — report win rate and profit factor degradation. Given how cost-sensitive a 1:1 system is, this test is the most important gate in the whole spec: if profitability collapses under 2x costs, the system is not viable at all, not just less profitable
- Test explicitly during a known high-volatility news window even with the blackout filter active, to confirm no edge-case entries slip through near the blackout boundary
9.6 Before Live Deployment
- Minimum 4-6 weeks forward-testing on a demo account matching the target broker's real spread/execution, specifically because backtested spread models tend to understate real-world cost on small-stop scalp systems
10. Deliverables Expected From Developer
- Compiled EA file (.ex4 or .ex5) matching platform specified
- Full source code, commented
- Backtest report (per Section 9) as exported HTML/PDF from the strategy tester, including the explicit breakeven-win-rate-vs-achieved-win-rate comparison and the 2x-cost stress test result
- Written summary of assumptions/deviations from this spec, with rationale — particularly if the rejection-candle wick % or ATR band needed adjustment to get a workable trade frequency