Skip to content
All library documents

Cosine-Based Trend Direction Dots for MetaTrader

Article MQL5 code base

Summary

This document explains a chart indicator that marks trend direction with colored dots: blue indicates bullish conditions and red indicates bearish conditions. Its calculation uses the cosine of price-change angle and obtains input prices through a moving-average function, with the selected price type determining which values it uses.

Users can adjust the calculation period, input price, spike filter, and horizontal or vertical display shifts. A longer period increases lag while reducing false signals, according to the description; the filter is presented as a way to suppress spikes without adding lag. No testing results, market examples, or performance evidence are provided, so the dots should be treated as a directional visualization rather than proof of a profitable signal. The document also does not specify how the angle is normalized or how parameter settings should be selected for a particular market or timeframe.

Key ideas

  • The indicator uses the cosine of price-change angle to represent trend direction.
  • Blue dots mark bullish direction, while red dots mark bearish direction.
  • A longer period increases lag but is described as reducing false signals.
  • The filter is intended to reduce spike effects without adding lag.
  • Applied price and display shifts are configurable.

Tags

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