OPEN-SOURCE SCRIPT
Updated

ZigZag HTF

17 561
Here is my 'ZigZag' without using 'security'

There are 2 options:


Be aware, although the ZigZag is mostly correct, a bar which is at the same time a pivothigh and a pivotlow can give unwanted results.
Regretfully for now I haven't be able to improve this.

tradingview.sweetlogin.com/proxy-s3/snapshots/l/LoyKMsbv.png

Cheers!
Release Notes
mauryashivnarayan4, germanherraiz,

I'm sorry, but I don't see it repaint for now
It could be I'm missing something, if that is the case, please send me examples

Now, the idea is all about pivothigh's and pivotlow's

Let's take an example of a pivothigh at a 1h TF.

A highest point needs to have at least 1 lower bar at the right ('future') before it can be a highest point (= pivothigh).
For example there can be only a 12h pivothigh if the 13h bar high is lower (when the 13h bar is closed).

When we do this on a 15' TF, where there are 4 bar's (and not 1) in 1h, the right side should have at least 4 lower high bar's.

In that case after 5 bars there could be a new 1h ZigZag appearing on a 15' chart

I've included labels where a ZigZag normally should be further than the according TF label
Release Notes
Added TF's 1', 3', 5', 10'

Also enhanced script

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.