NinjaTrader Divergence Indicator

NinjaTrader Divergence Indicator
The NinjaTrader Divergence Indicator is designed to detect divergence, which signals a potential trend reversal or continuation. The indicator determines the regular (classic) and hidden divergence calculated based on the RSI, Stochastic and MACD oscillators.

NinjaTrader Divergence Indicator

NinjaTrader Divergence Indicator is designed to determine the well-known trading concept – divergence on the classic RSI, Stochastic and MACD technical analysis indicators.

ninjatrader 8 divergence indicator


A divergence is formed on the chart when the price of an asset moves in the opposite direction of the technical indicator. Divergence is used by traders as a signaling feature of a possible trend reversal or its continuation (the price will continue to move in its current direction). The detected divergence is a reliable signal, but is rarer than standard oscillator signals.

The indicator developed by us detects divergence on three technical indicators – RSI, Stochastic and MACD, the parameters of which you can change according to your personal preferences.

In order not to miss trading signals, various types of alerts can be configured.

The indicator defines two types of divergences – regular (classic) and hidden. If you use only one type of divergence for analysis, you can disable the unused one in the settings.


How to trade using NinjaTrader Divergence indicator?

The indicator visualises detected divergences in the form of lines connecting price extremes (maximum and minimal price values), as well as entry triangles (pointers) that display the proposed trading direction.

Green triangles are for buying (long) trades, while red triangles signal potential selling (short) trades. Depending on the type of divergence – bearish or bullish – the lines are colored red or green.

divergence cheatsheet


Regular (classical) divergence

It signals a possible trend reversal.

Regular bullish divergence – price makes lower minimums and the oscillator makes higher minimums.

Regular bearish divergence – price makes a higher mахimum and the oscillator makes a lower maximum.

They are displayed on the chart as solid lines.

Hidden divergence

It signals a possible continuation of the trend.

Hidden bullish divergence – price makes a higher minimum, but the oscillator makes a lower minimum.

Hidden bearish divergence – price makes a lower maximum and the oscillator makes a higher maximum.

They are displayed on the chart as dashed lines.

NinjaTrader Divergence indicator input parameters

The indicator has the following parameters:

rsi divergence indicator ninjatrader


Alerts – setting up various types of alerts.

BaseIndicator – indicator selection for detecting divergences.

LookbackPoints – defines the lookback period during which a divergence may occur.

EnableClassicDivergences – enable/disable the detection of regular (classic) divergences.

EnableHiddenDivergences – enable/disable detection of hidden divergences.


Custom Programming

mt4 custom programming
We can upgrade the presented indicator to suit your needs – add new functions, change the algorithm for calculating signals, or combine it with your other indicator, turning it into a single powerful tool for your trading strategy.

We can also turn the indicator into an Automated Trading Strategy with an extended set of custom functions (stop loss, take profit, trailing stop, risk management parameters, trading time limit, and others).

Request a free consultation from our team of professional programmers and find out the cost and timing of your project development.


Nordman Algorithms is not liable for any risk that you face using the software. Please, use the software on your own responsibility. The software is coded in accordance with a common known concept and Nordman Algorithms does not guarantee accuracy or trading performance of the software signals.

See other indicators on a single subscription
NinjaTrader TTM Squeeze Indicator
NinjaTrader Ichimoku Indicator
NinjaTrader SuperTrend Indicator