Skip to content
All library documents

A Trend-Following EA Triggered by Slope Direction Line Color Changes

Article MQL5 code base

Summary

This Expert Advisor uses the SlopeDirectionLine trend indicator to generate trades when a bar closes and the indicator’s line changes color. The document describes a close-confirmed signal rather than an intrabar trigger, and notes that the compiled indicator must be installed in the terminal’s indicator folder for the EA to operate.

It also mentions a library that supports brokers with nonzero spreads and allows stop-loss and take-profit settings when opening positions. The cited historical test used default EA inputs, omitted stop loss and take profit, and covered USDJPY on a four-hour chart during 2013. Although the page refers to test charts and deal history, it provides no numerical performance metrics in the text. A single historical period and instrument cannot establish robustness or expected future results.

Key ideas

  • The EA trades on a color change in the trend indicator confirmed at bar close.
  • The compiled indicator file must be available in the terminal’s indicator folder.
  • A supporting library is described as enabling nonzero-spread brokers and optional stop-loss and take-profit settings.
  • The cited test used USDJPY on a four-hour chart in 2013 with default inputs and no stop loss or take profit.
  • The document supplies no numerical performance results or evidence of robustness.

Tags

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