Skip to content
All library documents

ATR and Risk-Reward Breakeven Methods for Automated Trading

Article MQL5 articles

Summary

This article describes two ways to move a trade's stop toward breakeven in an MQL5 expert advisor. The ATR method sets both the activation distance and the stop offset as multiples of average true range, adapting the thresholds to measured volatility instead of using fixed points. The risk-reward-ratio method uses a predefined reward relative to risk. The article also develops classes to configure these modes and integrate them with an Order Blocks advisor.

It compares backtests with no breakeven mechanism, fixed-point breakeven, ATR breakeven, and two risk-reward settings. The reported comparison suggests that the higher risk-reward setting performed better for the tested strategy, and the author cautiously proposes that RRR-based breakeven may suit strategies targeting at least a three-to-one reward-to-risk ratio. The article stresses that results are strategy dependent and should be evaluated individually. Its code and backtests illustrate implementation and comparison, but do not establish that either method will improve performance in other markets or systems.

Key ideas

  • ATR multiples can scale breakeven activation and stop offsets with measured volatility.
  • A larger ATR threshold generally means breakeven triggers less often.
  • Risk-reward-based breakeven ties the trigger to a strategy's predefined reward and risk.
  • The reported comparison favored the higher RRR setting for the tested Order Blocks advisor, but results may not generalize.
  • Compare breakeven variants against a no-breakeven baseline for each strategy.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.