Trendoscope

HhLl-Oscilator

Simple oscillator which checks how many highs and how many lows the price is making. Parameters are as explained below:

lookback - Checks how many highs and lows it is making in these many bars. Sum of all highs and lows are taken for plotting.
periods - Initial period to check high and lows
multiples - Number of multiples on initial period for which highs and lows are checked
colorCandles - CandleColor based on the oscillator

If periods is 20 and multiples is 5 and loopback is 10

Indicator checks for last 10 bars how many highs/lows are made for 20, 40, 60, 80 and 100 periods. Sum of all highs and lows are plotted on the oscillator overlay

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.

Want to use this script on a chart?