This simple indicator identifies Wide Range Body (WRB) and Hidden Gap (HG) bars.
WRB patterns are displayed as a black dots in the middle of the candlestick’s body.
HG patterns are plotted as light blue dots.
Sometimes patterns are detected at the same time and the dots are plotted in the same candlestick body.
Indicator converted from pinescript version by a request in the Spanish forum.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
//PRC_WRB HG | indicator //06.09.2018 //Nicolas @ www.prorealcode.com //Sharing ProRealTime knowledge //converted from tradingview version //display dots for Wide Range Body and Hidden Gap patterns body = abs(open-close) if body>body[1] and body>body[2] and body>body[3] then wrb = (open+close)/2 drawtext("●",barindex,wrb,dialog,bold,20) coloured(100,100,100) else wrb=0 endif if (wrb[1]>0 and (low>high[2] or high<low[2])) then hq = wrb[1] drawtext("●",barindex[1],hq,dialog,bold,10) coloured(0,255,255) endif return |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Hi Nicolas, sorry for my ignorance, but what’s the use of this indicator?
These 2 patterns are used in price action trading.
Thanks Nicolas, I really like this graphical help on the price that identifies the WRB and Hidden Gaps. I found various educational materials on the web and one of the most interesting seemed to me this. Here is the link: http://www.thestrategylab.com/WRBAnalysis.htm
Thank you Nicolas, is there any way that an alert can be set for when the dot appears?
yes, change the last line with:
RETURN wrb,qh
and set an alarm with the alert tool for each time one of these 2 values are changing.
Thank you Nicolas, I will try it.