The idea is rather simple. If high of the current bar is higher than high of the previous bar, and close of the current bar is lower than high of the previous bar, it is considered as a false breakthrough up. Correspondingly, if low of the current bar is lower than low of the previous bar and close of the current bar is higher than low of the previous bar, we have a false breakthrough down.
There are situations when in one bar will be two false breakthroughs - if the bar is an external in relation to the previous bar, and its close is in the previous bar's range. The indicator displays:
The essence is that if, for example, on the last five bars were 3 (or more) false breakthroughs, then, most probably, the next breakthrough high or low (the previous bar) will be true.
Translated from Russian by MetaQuotes Software Corp.
Original code: https://www.mql5.com/ru/code/1562
The Acceleration/Deceleration Indicator (AC) measures acceleration and deceleration of the current driving force.Average Directional Movement Index (ADX)
The Average Directional Movement Index Indicator (ADX) helps to determine if there is a price trend.