On a chart, the Keltner Channel indicator is similar in appearance to Bollinger Bands, but with less wildness and separation of the outer bands. The Keltner Channel can be used alongside other indicators to help confirm entry and exit points.

## Calculating the Keltner Channel

The Keltner Channel comprises one middle and two outer lines or Bands. The Middle Band is nothing more than a simple moving average (SMA) of the Typical Price, the Typical Price being the average of the high, low, and close of the bar, or (H+L+C)/3. You can also think of this as the Trend Line.

The Outer Bands are then calculated using an ATR of the same period and timeframe as the Middle Band SMA.
Upper Band = SMA + ATR.
Lower Band = SMA – ATR.

That’s it! A simple calculation, but the ATR bands allow instant visualization of how fast the price is moving in relation to the Trend Line.

## Keltner Channel PIN Settings

For each timeframe you can select a different mode:

• Disabled (D) – The timeframe will be ignored.
• Breakout (B) – Gives a signal when the price crosses from inside to outside the Outer Bands.
• Reverse (R) – Gives a signal when the price crosses from outside to inside the Outer Bands.
• Trending (T) – Price closing above the Upper Band is a buy signal. Price closing below the Lower Band is a sell signal.
• Overbought/sold(O) – Gives the opposite signal to Trending, e.g. a sell signal when the price closes above the Upper Band, and a buy signal when the price closes below the Lower Band.
• Last Band Crossed (L) – The pin will look backwards a number of candles as set by the Bars to search parameter, and will set the signal based on the last Outer Band to be touched by the price, and will remain set for the specified number of bars. E.g. Bars to search is set to 5, the pin will look back to see if the price closed outside a Band within the last 5 bars. If the price closed above the Upper Band, a buy signal is set, and if the price closed below the Lower Band a sell signal is set. If neither of the Outer Bands was crossed, then the signal will be none. If a buy or sell signal is set it will remain set until either a) the opposite Outer Band is crossed or, b) the signal expires. The signal will expire when the number of bars specified (Bars to search) have closed without an Outer Band being crossed.

Other important settings are:

• Keltner Period – Set the period of the SMA and ATR.
• Bars to search (Mode L) – In Last Band Crossed mode, specifies how far back to search for a candle crossing an Outer Band.

## Keltner Channel MTF PIN Change Log

``````//+------------------------------------------------------------------+
//|                                          Keltner Channel MTF PIN |