Skip to content
All library documents

CCI and Moving Average Signals with History-Based Position Sizing

Article MQL5 code base

Summary

The document outlines an expert advisor that combines the Commodity Channel Index with a moving average and trailing behavior. It notes that the CCI level is treated as an integer and that users can choose the current and previous bars used for its values. The moving average uses a selected current bar and the next older bar to calculate a difference, or delta.

Position volume is described as being calculated from trading history, with controls for maximum risk as a percentage, a reduction factor that activates after losing trades, and the number of historical days to examine. These features suggest a signal and sizing framework, but the page does not specify exact entry or exit conditions, the trailing method, formulas for sizing, or tested results. The description alone is not enough to assess robustness or determine appropriate risk settings.

Key ideas

  • The expert advisor combines CCI and moving average inputs with trailing behavior.
  • CCI settings include a level and the current and previous bars used for readings.
  • The moving average comparison uses a current bar and the next older bar to derive a delta.
  • Position size is linked to recent trading history and a maximum percentage risk setting.
  • A reduction factor is described for use after losing trades, but sizing details and performance evidence are absent.

Tags

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