EA Configurations
EA CONFIGURATIONS
Key Parameters:
- Slippage:
- Defines the maximum allowable slippage (in points) for opening trades.
- If the slippage exceeds this value, the trade will not be executed.
- Note: This value is used internally by the EA, but many brokers may not honor it consistently.
- Example: If
Slippage = 3, the EA will attempt to open trades with a maximum slippage of 3 points. Trades with greater slippage will be rejected.
- MagicNumber:
- A unique identifier used by the EA to track its own trades.
- This ensures the EA can distinguish its trades from those opened by other EAs or manually.
- Use Cases:
- If running multiple EAs on different pairs, the same MagicNumber can be used.
- If running multiple EAs on the same pair, assign each EA a unique MagicNumber to avoid conflicts.
- Example MagicNumbers:
- EA on EURUSD:
23423410 - EA on GBPUSD:
23423411 - EA on EURUSD (second instance):
23423412
- EA on EURUSD:
- TradeComment:
- Allows you to set a custom comment for trades opened by the EA.
- This comment is visible in the trade terminal and helps identify trades opened by the EA.
- Example: If
TradeComment = "TrendFollower", trades will appear in the terminal with this label.
- Disable Check Error to Open Trade:
- True: Disables the EA’s built-in checks before sending a trade command to the broker.
- False: Enables the checks.
- Explanation:
- The EA performs predefined checks, such as ensuring there is enough margin, avoiding stoplevel areas, or adhering to other broker-specific rules before opening trades.
- If your broker has unique conditions causing these checks to block valid trades, set this to True to bypass them.
- Disable Market Close Error:
- True: The EA ignores market close conditions and continues attempting to open trades.
- False: The EA will not open trades if the market is closed.
- Use Case:
- Useful in backtesting when the broker’s market hours differ from standard trading hours, which might cause the EA to halt.
- If your backtest is stuck due to market close conditions, set this to True and retry.
Important Notes:
- Slippage: While the EA can control slippage during trade execution, brokers may still execute trades at a different price due to market conditions.
- MagicNumber: Properly configuring MagicNumbers is critical when running multiple EAs to prevent trade management conflicts.
- Error Checks: Use the
Disable Check Error to Open Tradeoption with caution, as disabling error checks can lead to trades being rejected by the broker. - Backtesting: The
Disable Market Close Errorsetting is specifically helpful for backtesting and may not be required during live trading.
Risk warningTrading involves risk. You could lose more than your initial investment. Hypothetical / past performance does not guarantee future results.