TradingView
nephew_sam_
27 jun 2022 12:28

Market Structure Patterns (Nephew_Sam_) 

British Pound/U.S. DollarFXCM

Beskrivning

This market structure indicator plots HH/LL labels with a little twist - it can identify upto 14 custom patterns of your choice!

Indicator settings:
Pivot strength - highest or lowest point in a number of x left+right bars
Show - show zigzag lines, HHLL labels, Pattern Matches
Patterns - upto 14 patterns (7 bear, 7 bull) with custom label text
Styles - for labels and lines

Disclaimer
- Although 90% of this indicator is custom coded, I have to give credits to LonesomeTheBlue (tradingview.com/u/LonesomeTheBlue/) for his "Double Zig Zag with HHLL" indicator where I got the logic on how to plot the labels in real time.
- This indicator repaints labels in realtime (not historical candle)

Versionsinformation

Added BOS line

Versionsinformation

Bug fix

Versionsinformation

Watermark
Kommentarer
Slick_SiD
I’ve found my strategic home in smart money concepts like this and I deeply appreciate that this one was open source. Cheers, Great work
Ouch1230
nephew_sam_
@Ouch1230, Thank you!
Yeaaaaaaaaaaaaaaaaaaaaaaaaaah
plh and fbos what does it stand for
sfcbraham150560
@Yeaaaaaaaaaaaaaaaaaaaaaaaaaah, PLH (no clue but I’d guess it’s something to do with lower highs) FBOS (some sort of break of structure).. sorry, I tried Lol
TradeTheCloud
Its cool, but I gotta be honest, the repainting is a buzz-kill. If you can make it so that the signals dont repaint, that would be awesome
nephew_sam_
@TradeTheCloud, Again, another stupid comment about repainting. This isn't a signals indicator, instead it only identifies patterns. The labels react to what the price and pattern is.

No signals indicator alone will make you profitable.
fxhundredths
Looks super powerful although i tested it and gained huge on 5M Timeframe thank you
Slick_SiD
I figured out how to add BOS alerts for this awesome indicator. For any interested in BOS alerts add these 2 lines at the bottom of the source code.
Note on the alerts. The BOS alerts are accurate but if they are set to "Once Per Bar Close" they keep going off aafter triggered for some reason. You can avoid this by choosing "Only Once" but you will have to reactivate them after triggered

alertcondition(isMatching(bosBullMatchPattern, zigzag_hhll), title="Bullish BOS", message='Bullish Break Of Structure')
alertcondition(isMatching(bosBearMatchPattern, zigzag_hhll), title="Bearish BOS", message='Bearish Break Of Structure')
Slick_SiD
@Slick_SiD, disregard I spoke too soon on the alert code lines. They do alert on BOS but also alert seemingly randomly somehow based on the zigzag. Sorry guys
Mer