Login Page - Create Account

Technical Studies Reference


Commodity Channel Index

The Commodity Channel Index (CCI) measures the variation of a symbols price from its statistical mean. High values show that prices are unusually high compared to average prices, whereas low values indicate that prices are unusually low. It can be used with any type of symbol, not just commodities.

Let \(X\) be a random variable denoting the Input Data, and let \(X_i\) be the value of the Input Data at Index \(i\). Let the Inputs Length and Multiplier be denoted as \(n\) and \(v\), respectively. Then we denote the Commodity Channel Index at Index \(t\) for the given Inputs as \(CCI_t(X,n,v)\), and we compute it for \(t \geq n\) in terms of Simple Moving Averages as follows.

\(\displaystyle{CCI_t(X,n,v) = \frac{X_t - MA_t(X,n)}{\frac{v}{n}\sum_{i = t - n + 1}^t|MA_t(X,n) - X_i|}}\)

Note: Depending on the setting of the Input Moving Average Type, the Simple Moving Averages in the above formula could be replaced with Exponential Moving Averages, Linear Regression Moving Averages, Weighted Moving Averages, Wilders Moving Averages, Simple Moving Averages - Skip Zeros, or Smoothed Moving Averages. The types of all three Moving Averages in the calculation are determined by this one Input.

This study also displays horizontal lines whose levels are determined by the Line2 Value and Line3 Value Inputs.

Inputs

Spreadsheet

The spreadsheet below contains the formulas for this study in Spreadsheet format. Save this Spreadsheet to the Data Files Folder.

Open it through File >> Open Spreadsheet.

Commodity_Channel_Index.20.scss


*Last modified Monday, 26th September, 2022.