Skip to content
All library documents

A Moving Average Limit-Order Strategy with Tight Stops and Targets

Article MQL5 code base

Summary

The document describes an Expert Advisor that places a pending buy-limit or sell-limit order at the value of a moving average, identified as MA(590-M1). As the moving average changes, the pending order is amended to follow it. Once filled, the order is left unchanged and exits through a tight stop-loss or take-profit. When no orders remain, the program submits a new pending order. The stated stop is 30 points and the take-profit is 70 points.

The rationale is an observation that prices often cross a moving average and continue some distance, while some moves only touch the average and reverse. The author uses the small stop to limit exposure to such reversals. No backtest, trade sample, or performance statistics are provided, so the observation is not evidence of profitability. The source was reconstructed from a later version because the original was unavailable; the author acknowledges possible restoration errors. The document does not specify enough detail to assess instrument, timeframe conventions, spread, or execution assumptions beyond the moving-average label and point-based exits.

Key ideas

  • A pending limit order is placed at the current moving-average value and adjusted as that value changes.
  • The order stops being modified after it is triggered.
  • The described exits use a 30-point stop-loss and a 70-point take-profit.
  • A fresh pending order is placed after the previous orders are gone.
  • The strategy rationale is anecdotal, and the reconstructed source may contain errors.

Tags

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