Support & Resistance PA - Expert Advisor
Overview
Support & Resistance PA is a professional automated trading system based on advanced price action analysis. This Expert Advisor combines classical support and resistance levels with candlestick pattern recognition to identify high-probability trading opportunities at key Fibonacci levels.
Trading Strategy
Core Methodology
The EA implements a sophisticated price action strategy that operates within established support and resistance zones:
-
Dynamic S/R Level Detection
- Automatically identifies support and resistance levels based on historical price data
- Analyzes the last 100 bars (configurable) to determine key price zones
- Continuously updates levels as market structure evolves
-
Fibonacci Retracement Integration
- Calculates 50% and 61.8% Fibonacci levels between support and resistance
- Monitors price action at these critical retracement levels
- Uses Fibonacci zones as high-probability entry areas
-
Candlestick Pattern Recognition
- Morning Star Pattern (Bullish Reversal): Identifies three-candle bullish reversal patterns near the 50% Fibonacci level, signaling potential upward momentum
- Evening Star Pattern (Bearish Reversal): Detects three-candle bearish reversal patterns near the 50% Fibonacci level, indicating potential downward movement
Entry Rules
BUY Signal (Morning Star):
- Three-candle pattern detected: Bearish → Small body → Bullish
- Pattern forms near 50% Fibonacci retracement level
- Third candle closes above 50% of the first candle's body
- Entry: Market buy order
- Stop Loss: Below support level (or standard SL if enabled)
- Take Profit: Calculated based on 4-candle projection (or standard TP if enabled)
SELL Signal (Evening Star):
- Three-candle pattern detected: Bullish → Small body → Bearish
- Pattern forms near 50% Fibonacci retracement level
- Third candle closes below 50% of the first candle's body
- Entry: Market sell order
- Stop Loss: Above resistance level (or standard SL if enabled)
- Take Profit: Calculated based on 4-candle projection (or standard TP if enabled)
Position Scaling (Doubling Feature)
Breakout Confirmation:
- For BUY positions: If price breaks above resistance level, the EA opens an additional position with double lot size (0.2 lots default)
- For SELL positions: If price breaks below support level, the EA opens an additional position with double lot size (0.2 lots default)
- This strategy capitalizes on strong momentum breakouts and impulsive moves
Features
1. Intelligent Trade Management
- Automated lot size normalization to broker requirements
- Margin checking before opening positions
- Price and stop level validation
- Support for multiple order filling modes (FOK, IOC, RETURN)
2. Risk Management
- Adjustable initial lot size (default: 0.1)
- Configurable double lot size for breakouts (default: 0.2)
- Choice between dynamic S/R stop loss or standard fixed points
- Optional standard SL/TP mode (50 points each, customizable)
- Trailing stop functionality with adjustable distance and step
- Auto-close at profit target (15 pips default, configurable)
3. Advanced Trailing Stop
- Distance: 40 points (default, adjustable)
- Step: 1 point (default, adjustable)
- Respects broker's minimum stop level requirements
- Only moves stop loss in favorable direction
- Prevents "too close to market" errors with intelligent distance checking
4. Professional Visual Interface
Dashboard Display (Top-Left):
- Real-time account balance and equity
- Current profit/loss with color coding (green/red)
- Active signal status (BUY/SELL/WAITING)
- Trading session indicator (ASIAN/LONDON/NEW YORK)
- Open positions count
- Current support and resistance levels
- Range between S/R levels
Pattern Statistics Tracking:
- Morning Star Performance: Total trades, wins, losses, cumulative profit
- Evening Star Performance: Total trades, wins, losses, cumulative profit
- Color-coded results for easy analysis
Chart Visuals:
- Large centered symbol name in silver
- EA name "Support & Resistance PA" in gold
- Real-time market date and time display
- Golden support and resistance lines with labels
- Fibonacci levels at 50% and 61.8% (dashed gray lines)
- Percentage markers (0.00%, 50.00%, 61.80%, 100.0%)
Chart Color Scheme:
- Background: Dark blue-gray (#191E26)
- Bullish candles: Cyan/Aqua (#26DEC1)
- Bearish candles: Red (#EF5350)
- S/R lines: Gold (#B49650)
- Grid: Subtle dark lines for professional appearance
5. Optional Features
- Martingale: Can be enabled (default: OFF for safety)
- Auto-Close: Automatically closes positions at 15 pips profit (default: OFF)
- Standard SL/TP: Use fixed point values instead of dynamic S/R levels
Input Parameters
Trade Settings
- Initial Lot Size: 0.1 (adjustable)
- Double Lot Size: 0.2 (adjustable)
- Use Standard SL/TP: false (uses S/R levels by default)
- Standard Take Profit: 50 points
- Standard Stop Loss: 50 points
Martingale Settings
- Enable Martingale: false (OFF by default)
Trailing Stop Settings
- Trailing Stop: 40 points
- Trailing Step: 1 point
Auto Close Settings
- Enable Auto Close: false (OFF by default)
- Auto Close Profit: 15 pips
Pattern Detection
- Candles for TP: 4 (projection candles)
- Fibonacci 50% Level: 50.0
- Fibonacci 61.8% Level: 61.8
Support/Resistance Settings
- Lookback Bars: 100 (bars to analyze for S/R detection)
How It Works - Step by Step
-
Initialization
- EA starts and applies professional dark theme to chart
- Detects broker's lot size requirements and filling modes
- Sets up visual elements and dashboard
-
Market Analysis (Every New Bar)
- Scans last 100 bars to identify highest high (resistance) and lowest low (support)
- Calculates Fibonacci retracement levels
- Draws support/resistance lines with labels on chart
-
Pattern Detection
- Monitors price action for Morning Star or Evening Star patterns
- Validates pattern formation near 50% Fibonacci level
- Confirms pattern criteria (candle sizes, body relationships)
-
Trade Execution
- When valid pattern detected:
- Checks available margin
- Normalizes lot size to broker requirements
- Validates stop loss and take profit distances
- Places market order with appropriate SL/TP
- Records trade in pattern statistics
-
Position Management
- Breakout Monitoring: Watches for resistance/support breaks
- Position Doubling: Opens additional trade if breakout confirmed
- Trailing Stop: Adjusts stop loss as price moves favorably
- Auto-Close: Closes position if profit target reached (if enabled)
-
Statistics Tracking
- Records every Morning Star and Evening Star trade
- Tracks wins, losses, and profit for each pattern type
- Updates dashboard in real-time
- Analyzes closed positions from trading history
Best Practices
Recommended Settings
- Timeframe: H1 (1 Hour) or H4 (4 Hour) for best results
- Pairs: Major forex pairs (EURUSD, GBPUSD, USDJPY) or Gold (XAUUSD)
- Starting Balance: Minimum $1,000 for 0.01 lot, $10,000 for 0.1 lot
- Leverage: 1:100 or higher recommended
Risk Management
- Never risk more than 1-2% of account per trade
- Adjust lot sizes according to account balance
- Use proper position sizing based on stop loss distance
- Monitor pattern statistics to identify which patterns perform best
Optimal Conditions
- Works best in trending or ranging markets with clear S/R levels
- Most effective during high-liquidity sessions (London/New York overlap)
- Avoid major news events or extreme volatility periods
- Allow sufficient distance between support and resistance (minimum 50-100 pips)
Important Notes
- Margin Requirements: EA automatically checks margin before opening trades and will skip trades if insufficient funds
- Broker Compatibility: Compatible with all MT5 brokers; automatically adapts to broker's requirements
- Pattern Statistics: Statistics reset when EA is removed from chart or terminal restarted
- Netting Accounts: Fully optimized for netting account types (standard MT5 accounts)
- Backtesting: Thoroughly backtest on historical data before live trading
Technical Requirements
- Platform: MetaTrader 5 (MT5)
- Account Type: Netting (standard MT5)
- Minimum Deposit: $1,000+ recommended
- VPS: Recommended for 24/7 operation
- Internet: Stable connection required
Support
For questions, issues, or feature requests, please contact support or refer to the included user manual.
Disclaimer
Trading foreign exchange and contracts for difference on margin carries a high level of risk and may not be suitable for all investors. Past performance is not indicative of future results. This EA is provided as-is without warranty. Always test thoroughly on a demo account before live trading.
Version: 1.00
Copyright: Support & Resistance PA
License: Personal Use
Why Choose Support & Resistance PA?
Professional grade price action strategy
Beautiful visual interface with real-time statistics
Intelligent trade management with safety checks
Adaptive to market conditions with dynamic S/R levels
Position scaling on breakouts for maximum profit
Comprehensive risk management tools
Transparent performance tracking for each pattern type
Trade smarter with Support & Resistance PA - Where Price Action Meets Automation!