Dual Session Breakout
- Uzmanlar
- Sürüm: 1.0
- Etkinleştirmeler: 10
Dual Session Breakout trades the ranges of two sessions, London and New York, each with its own time zone, range, trade window and entry mode. Three entry modes are available for each session: breakout, retest and fakeout. A stop loss on every trade, no grid, no martingale.
By default the London session measures the night range from 00:00 to 07:00 London time and trades its breakout with stop orders until 11:00. The New York session measures the range from 08:00 to 09:30 New York time and trades the fakeout: when price closes beyond the range and then closes back inside, the EA enters in the opposite direction, with the stop beyond the false extreme and the target on the other side of the range. Every setting can be changed for each session.
The breakout mode places a buy stop above the range and a sell stop below it; when one fills the other is cancelled, and after a closed trade the orders are placed again while trades and time are left. The retest mode waits for a close beyond the range, then enters when price comes back to the broken level and closes on the breakout side. The fakeout mode trades the return inside the range after a failed breakout.
Exits include a target in R multiples, break even, a partial close, a trailing stop on the M15 ATR or on the last M15 candles, an optional close time for each session and a weekend close on Friday. Optional prop firm rules follow the daily loss, the overall drawdown and a profit target on every tick, with balances saved across restarts. The chart panel shows the state of each session and statistics by session and by weekday. An optional AI filter can review each setup; it is off by default and works only in live trading, because MetaTrader allows web requests only there.
Range size and spread are measured against the daily ATR and the range itself, not in pips, so the same settings work on gold, indices and currencies. The default values were developed on XAUUSD. Each time zone follows its own daylight saving calendar and the broker clock is converted automatically. Backtest on your broker's data for the symbol you trade, then forward test on a demo account.
Hedging and netting accounts. On netting accounts the EA keeps one position at a time on the symbol. Session 1 uses the Magic Number and session 2 the Magic Number plus 1. No DLL.
PARAMETERS
General
Magic Number: session 1 uses this number, session 2 this number plus 1. Use different numbers for each instance.
Session 1 and Session 2
Enabled: turns the session on or off.
Name: label used in the panel and in the journal.
Time Zone: London or New York. All times of the session are local time of this zone.
Range Start, Range End: the range. A start later than the end means the range starts the evening before.
Trade Window End: no new entries after this time; pending orders are removed.
Entry Mode: Breakout, Retest or Fakeout.
Max Trades Per Day: trades of this session per day. With more than one, the session re-arms after a closed trade.
Close Positions At Close Time, Close Time: optional daily close of the positions of this session.
Server Time
Server Time Mode: Auto reads the broker offset live and uses the New York close clock (GMT+2/+3) in the Strategy Tester. NY Close and Fixed Offset can be set by hand.
Fixed Server Utc Offset Hours: broker offset from UTC for Fixed Offset.
Entries
Trade Direction: Both, Long Only or Short Only.
Entry Buffer Percent Of Range: distance of the breakout levels beyond the range, as a share of the range.
Retest Max M1 Bars After Breakout: how long the retest mode waits for the return to the level.
Fakeout Max M1 Bars Outside The Range: a return inside the range within this time counts as a fakeout.
Fakeout Target Opposite Side Of Range: fakeout trades target the other side of the range instead of an R multiple.
Range Filters
Daily ATR Period: ATR on the daily chart used by the filters.
Min Range Percent Of Daily ATR, Max Range Percent Of Daily ATR: days with a range outside these limits are skipped.
Max Spread Percent Of Range: no entries when the spread is larger than this share of the range, 0 = off.
Trade Monday to Trade Friday: weekdays the EA trades.
Stop And Target
Stop Loss Mode For Breakout And Retest: Middle Of Range or Opposite Side Of Range. Fakeout stops sit beyond the false extreme.
Target In R Multiples: take profit as a multiple of the risk, 0 = no target.
Break Even At R, Break Even Lock In R: once the profit reaches this many R, the stop moves past entry by the lock. 0 = off.
Partial Close At R, Partial Close Percent: closes this share of the position once, at this many R. 0 = off.
Trailing Stop
Trailing Mode: Off, ATR or Candles.
Trailing Start At R: the trailing starts at this profit in R.
Trailing ATR Multiplier: distance in multiples of the M15 ATR 14.
Trailing Candles: the stop follows the lowest low or highest high of this many closed M15 candles.
Weekend
Close Before Weekend, Friday Close Time London: closes positions and removes orders on Friday at this London time.
Risk
Size Mode: Risk Percent sizes each trade from the stop distance, Fixed Lots uses a fixed volume.
Risk Percent Per Trade, Fixed Lots: size per trade. Lots are rounded down to the volume step.
Max Trades Per Day All Sessions: cap across both sessions, 0 = no limit.
Prop Firm Rules
Use Prop Firm Rules: off by default.
Max Daily Loss Percent: when equity falls this far below the balance at the daily reset, positions are closed and entries stop until the next reset.
Max Overall Drawdown Percent: when equity falls this far below the initial balance, positions are closed and the EA stops until restarted.
Profit Target Percent: the EA stops when the balance reaches this gain, 0 = off.
Daily Reset Hour Server Time: hour of the daily reset.
Initial Balance, Reset Saved Balances On Start: the starting balance of the challenge, saved across restarts. 0 uses the saved value or the current balance.
AI Filter
AI Mode: Disabled, Advisory Log Only or Filter. In Filter mode the setup is skipped when the AI rejects it, and the AI can restrict the day to buys or sells.
AI Min Confidence, AI On Failure: approval threshold and behaviour when no provider answers.
AI Min Seconds Between Calls, AI Max Calls Per Day, AI Max Response Tokens, AI Timeout Seconds: limits of the AI requests.
AI Extra Instruction: your own text added to the prompt.
AI Providers: Groq, DeepSeek, OpenRouter, OpenAI, Gemini and Claude, each with Enabled, Api Key and Model, tried in this order. Add the address of each provider you use in Tools, Options, Expert Advisors, Allow WebRequest for listed URL: api.groq.com, api.deepseek.com, openrouter.ai, api.openai.com, generativelanguage.googleapis.com, api.anthropic.com, each with https at the start.
Visual
Show Range Boxes And Levels, Session 1 Box Color, Session 2 Box Color, Buy Level Color, Sell Level Color: ranges and levels on the chart.
Show Panel With Statistics: state of each session, statistics by session and weekday, prop and AI status.
About Algotrend: Algotrend is an independent developer of trading algorithms. Every product is designed, tested and supported by the same developer. For questions, presets and updates, write in the comments of this page or send a private message on MQL5.
Trading involves risk. Results in the Strategy Tester do not guarantee future results.
