Cci Trend (Momentum)
Lambert's Commodity Channel Index traded as designed: buys when CCI pushes above +100, marking a move strong enough to call a trend, and sells when it breaks below -100.
How It Works
- Compute the 20-bar CCI from each bar's typical price — the average of its high, low and close — measuring how far the bar sits from its recent average in units of normal deviation.
- Buy when CCI crosses above +100. In Lambert's original design this is not an overbought warning but the opposite: the point where a move is finally strong enough to be called a trend.
- Sell when CCI breaks below −100, marking a move of the same conviction in the other direction.
Worked example. The typical price pulls 4 above its 20-bar average while the mean deviation is 2, giving CCI ≈ 133 — past +100, so the strategy buys. The position is held through the trend until CCI eventually prints −120 and the trade is closed.
The Math Behind The Indicators
Everything runs on closing prices of the traded timeframe: P is a close, Pt today's close, and N counts bars — one bar is one candle of that timeframe, so 20 bars on a 1h chart is 20 hours.
- Commodity Channel Index (CCI)
- How far the bar sits from its recent average, measured in units of typical deviation. It works off the typical price — the average of the high, low and close — so it accounts for the whole bar rather than the close alone. The 0.015 constant is chosen so that ordinary movement lands roughly inside ±100, which makes a reading beyond ±100 the marker of a genuine trend rather than noise.
- \[\mathrm{CCI} = \dfrac{TP - \mathrm{SMA}_N(TP)}{0.015 \cdot \mathrm{MD}_N}, \quad TP = \dfrac{H + L + P}{3}\]
- Example: If the typical price is 104, its 20-bar average is 100 and the mean deviation is 2, then CCI = (104 − 100) / (0.015 · 2) ≈ 133 — above +100, so the move counts as a trend rather than routine drift.
Example Chart
Example Chart
Cci Trend (Momentum)
Real Data54/ 100Composite score
Metrics Per Trade
Metrics Per Trade
Real data · Cci Trend (Momentum)
Final Metrics
Final Metrics
Real data · Cci Trend (Momentum)
Scores
Scores
Real data · Cci Trend (Momentum)
Resampled Data58/ 100Composite score
Metrics Per Trade
Metrics Per Trade
Resampled data · Cci Trend (Momentum)
Final Metrics
Final Metrics
Resampled data · Cci Trend (Momentum)
Scores
Scores
Resampled data · Cci Trend (Momentum)