Skip to content
All library documents

Robust CCI Variants and a Trend Strength Modification

Article MQL5 articles

Summary

The article compares three Commodity Channel Index calculations: the conventional version using mean absolute deviation, a version normalized by standard deviation, and a robust variant using the Theil–Sen median of pairwise half-sums with median absolute deviations. It explains the calculations with a small illustrative series and describes why robust estimates may be more suitable for short samples and outliers, although they require more computation.

An Expert Advisor compares threshold-crossing rules on EURUSD hourly data for 2021. The standard-deviation version produced fewer trades and fewer large losses than the classic version; the robust version increased trade count while further reducing large losses. The author cautions that the trading rules need substantial improvement. A further indicator accumulates robust CCI values while they remain on one side of zero, intending to measure trend duration and strength; a reversal after unusually strong accumulated movement is suggested as a basic strategy idea, not established evidence of profitability.

Key ideas

  • Classic CCI scales price deviation from its mean by mean absolute deviation.
  • The article proposes standard-deviation and robust median-based alternatives to the classic normalization.
  • The robust version uses pairwise half-sums for its center estimate and median absolute deviations for dispersion.
  • In the reported EURUSD test, the robust variant reduced large losses, while the underlying entry and exit rules remained weak.
  • Accumulating CCI values between zero crossings is proposed as a measure of trend duration and strength.

Tags

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