Range Escape
- Experts
- Versione: 1.5
- Attivazioni: 5
# Range Escape EA - Range Breakout Expert Advisor for MT5
## Product Overview
Range Escape EA is a professional automated trading system designed for MetaTrader 5 that captures price breakouts from consolidation ranges. Using a sophisticated combination of technical analysis, dynamic risk management, and intelligent trade protection, this EA identifies high-probability breakout opportunities and manages positions automatically.
---
## Key Features
### Dual Strategy Modes
Choose between two proven trading approaches:
- **Market Breakout Mode** - Executes instant market orders when price breaks above the previous bar's high (Buy) or below the previous bar's low (Sell), capturing momentum at the earliest opportunity.
- **Pending Grid Mode** - Places strategic pending orders at graduated price levels with intelligent lot scaling, allowing you to enter at optimal prices without monitoring the screen.
### Advanced Trade Protection
Your capital is protected by multiple layers of risk management:
- **Dynamic ATR Trailing Stop** - Automatically adjusts stop loss based on market volatility, locking in profits as the trade moves in your favor while giving enough room for normal price fluctuations.
- **BreakEven Protection** - Moves stop loss to entry price once the trade reaches a specified profit level, eliminating risk while keeping profit potential.
- **Fixed Trailing Option** - Traditional point-based trailing stop for those who prefer simpler position management.
### Intelligent Risk Management
- **Risk Percentage Mode** - Automatically calculates position size based on a percentage of your account balance, ensuring consistent risk across all trades.
- **Capital-Based Sizing** - Set how much capital you want to allocate per 0.01 lot for precise position control.
- **Fixed Lot Option** - Use a constant lot size for all trades when you prefer manual control.
- **Margin Verification** - Automatically checks available margin before placing trades and adjusts position size to prevent margin calls, even on volatile instruments like Gold (XAUUSD).
- **Daily Drawdown Protection** - Stops trading if your daily loss limit is reached, preventing emotional revenge trading.
### Market Timing Controls
- **Session Filters** - Trade only during specific market sessions (Asia, London, New York) when liquidity is highest.
- **Weekend Protection** - Automatically closes all positions before the weekend to avoid gap risk.
- **Market Open Delay** - Wait after market opens on Monday to avoid irregular pricing.
- **Trade Frequency Limiter** - Set minimum minutes between trades to prevent overtrading.
### Additional Features
- **Spread Protection** - Prevents trading during high-spread conditions that increase transaction costs.
- **Fakeout Buffer** - Customizable breakout confirmation buffer to filter false breakouts.
- **Grid Level Management** - Automatic cancellation of pending orders that drift too far from current price.
- **New Bar Execution** - Trades only on new bar formation, preventing multiple entries on the same signal.
- **Detailed Logging** - Optional debug mode for backtesting analysis and live monitoring.
---
## Input Parameters
### Main Settings
| Parameter | Description |
|-----------|-------------|
| **Strategy Mode** | Choose between Market Execution (breakout) or Pending Order Grid |
| **Allow Buy Trades** | Enable/disable buy signals |
| **Allow Sell Trades** | Enable/disable sell signals |
| **Min Minutes Between Trades** | Cooldown period between trades (0 = no limit) |
| **Max Spread Allowed (Points)** | Maximum spread for trade execution |
| **Fakeout Buffer (Points)** | Buffer distance above/below previous bar for breakout confirmation |
| **Magic Number** | Unique identifier for EA trades |
| **Trade Comment** | Text label attached to all trades |
### Pending Order Grid Settings
| Parameter | Description |
|-----------|-------------|
| **Max Grid Levels Per Direction** | Maximum number of pending orders placed in each direction |
| **Grid Step Between Orders (Points)** | Distance between each grid level |
| **Max Distance to Target for Grid** | Maximum distance from current price to place grid orders |
| **Lot Scaling Factor** | Multiplier for lot size at each grid level (closer = larger) |
| **Cancel Orders Beyond This Distance** | Distance threshold for automatic order cancellation |
### Trade Management
| Parameter | Description |
|-----------|-------------|
| **Trailing Stop Mode** | Choose between Off, Fixed, BreakEven, or ATR-based trailing |
| **Take Profit (Points)** | Profit target in points (0 = disabled) |
| **Stop Loss (Points)** | Initial stop loss in points |
| **BreakEven Trigger (Points)** | Profit level to move stop to entry price |
| **Fixed Trailing Distance (Points)** | Trailing stop distance for fixed mode |
| **Trail Step Sensitivity (Points)** | Minimum price movement before updating trailing stop |
| **ATR Period** | Number of bars for ATR calculation |
| **ATR Multiplier** | Volatility multiplier for ATR-based trailing distance |
| **ATR Timeframe** | Timeframe for ATR indicator |
### Risk Management
| Parameter | Description |
|-----------|-------------|
| **Lot Calculation Mode** | Choose Fixed, Risk Percentage, or Capital Per 0.01 Lot |
| **Fixed Lot Size** | Constant lot size for fixed mode |
| **Risk Percentage Per Trade** | Account percentage at risk per trade |
| **Capital Per 0.01 Lot** | Capital allocation per micro lot |
| **Use Equity Instead of Balance** | Calculate risk based on equity including floating P/L |
| **Max Daily Drawdown %** | Stop trading when daily loss limit is reached (0 = off) |
| **Daily DD Unit** | Daily drawdown measured in percentage or currency |
| **Max Risk % Per Trade** | Hard cap on risk percentage |
| **Maximum Lot Size Allowed** | Absolute maximum lot size limit |
### Market Filters
| Parameter | Description |
|-----------|-------------|
| **Close Trades Before Weekend** | Close all positions before Friday market close |
| **Friday Close Minutes Before** | Minutes before market close to exit trades |
| **Monday Delay Minutes After** | Wait time after Monday market open |
| **Asia Session** | Allow trading during Asian session (00:00-08:00 GMT) |
| **London Session** | Allow trading during London session (08:00-16:00 GMT) |
| **New York Session** | Allow trading during NY session (13:00-21:00 GMT) |
### Debug
| Parameter | Description |
|-----------|-------------|
| **Enable Detailed Logging** | Show detailed trade calculations and filter status |
---
## How It Works
1. **Signal Generation** - On each new bar, the EA compares the current Ask/Bid price with the previous bar's high and low plus a fakeout buffer.
2. **Filter Validation** - The signal must pass all active filters (spread, session, frequency, drawdown, weekend, margin).
3. **Position Sizing** - Lot size is calculated based on your chosen risk parameters and verified against available margin.
4. **Trade Execution** - Market orders are executed immediately, or pending orders are placed at strategic grid levels.
5. **Active Management** - Open positions are continuously monitored with trailing stops, breakeven protection, and automatic SL adjustment.
6. **Order Maintenance** - Pending orders that drift too far from the market are automatically cancelled to keep the grid relevant.
---
## Recommended Usage
- **Best Timeframes**: H1, H4, D1 for breakout strategies; M15, M30 for active trading
- **Best Instruments**: Major forex pairs (EURUSD, GBPUSD, USDJPY), Gold (XAUUSD)
- **Account Type**: Works with both Netting and Hedging accounts
- **Minimum Deposit**: $500 recommended (varies by instrument and lot size)
