Commodity Channel Index (CCI)
    • Dark

    Commodity Channel Index (CCI)

    • Dark

    Article summary

    DXcharts powers DXtrade, DXfina, and FinCharts.
    Check our website to find more information about DXcharts library.

    Commodity Channel Index (CCI) is a momentum oscillator that represents security price's variation calculated from its statistical mean (average absolute deviation). To plot the variation, CCI first calculates the difference between a Typical Price (arithmetic average of the high, low, and close prices) and its Simple Moving Average (SMA). Then, the indicator divides the result by the statistical mean of the typical price. 

    CCI has two adjustable overbought and oversold levels and the zero line. When the oscillator's line moves above the zero line, it indicates strengthening of the market momentum. Moving below the zero line indicates the market momentum weakening.

    CCI = [TPn - SMAn (TP)] / [0.15 x MDn (TP)]

    TPn – Typical Price for n-period
    SMAn – Simple Moving Average for n-period
    MDn – Mean Deviation for n-period
    0.15 – Lambert's constant
    n – the number of periods

    Commodity Channel IndexCommodity Channel Index


    LengthThe number of periods the indicator uses to calculate the CCI
    OverboughtThe price value to fix the overbought level at
    OversoldThe price value to fix the oversold level at


    The plot renders the data you are working with on the chart. You can show/hide a plot by clicking the corresponding item in the settings. Every plot has a set of basic settings that you can change: color, weight, and type.

    CCIThe Commodity Channel Index plot
    OverboughtThe overbought level
    OversoldThe oversold level
    ZeroThe zero level

    Click the color rectangle under the plot's name to open the palette. Use the slider at the bottom to set the opacity of the color.


    To create a custom color:

    1. Clickto open the color picker
    2. By using the slider at the bottom, adjust the main color
    3. Then, set a shade for the main color on the palette

    The custom-created colors are added to your palette. To remove a custom color, drag it out of the palette.

    Change the value (in px) to adjust the thickness of the plot.
    The following plot types are available:
    • Linear. The plot is displayed as a line.
    • Column. The plot is displayed as a histogram.
    • DifferenceThe plot is displayed as a line which represents the difference between High and Low prices of the bar.
    • PointsThe plot is displayed as points.
    • Text above candleThe plot is displayed as the price labels above candles on the chart.
    • Text below candleThe plot is displayed as the price labels below candles on the chart.
    • Triangle above candleThe plot is displayed as triangles above candles on the chart.
    • Color candle. The candles on candle-type charts are highlighted with specified colors.


    Check Overlaying to display the indicator on the chart. Otherwise, the indicator is shown in a study pane down below.

    Note: To reset the settings, click Restore to Default next to the SETTINGS: INDICATOR'S TITLE