LazyBear

Belkhayate Timing [LazyBear]

--- Update April 11, 2015 ----

I have merged in @TheMighyChicken's code (Thanks!) and added some more options. Updated source here - pastebin.com/fVx5Bugi

Changes:
--------------
- Switch between plain candles and colored oscillator candles.
- Switch between candles and plain oscillator view.


--- Original Description ---

Belkhayate Timing, by Mostafa Belkhayate, is very famous in the Forex groups. This is a port from one of the MT4 versions available. If you have used this in other platforms, do let me know if this looks compared to those.

The usage is similar to that of ValueChart (www.tradingview.com/v/vqWXNNq2/). The middle area is the centroid or neutral area, the shaded regions (red/green) are extreme and beyond those are AlertZones. This seems to be used in conjunction with his other indicators, but, in my limited testing, I have seen this give a lot of good signals, especially on divergences.

Indicator allows coloring bars based on the oscillator position or show oscillator histogram (Check the options page).

Histogram=ON:

No Oscillator Smoothing:

@TheMightyChicken Can you do your candle magic on this oscillator too, just like you did for ValueChart? :)

More Info:
www.forexfactor.../attachment.php?attachment...

List of my public indicators: bit.ly/1LQaPK8
List of my app-store indicators: blog.tradingview.com/?p=970

List of my free indicators: bit.ly/1LQaPK8
List of my indicators at Appstore: blog.tradingview.com/?p=970
オープンソーススクリプト

TradingViewの精神に則り、このスクリプトの作者は、トレーダーが理解し検証できるようにオープンソースで公開しています。作者に敬意を表します!無料で使用することができますが、このコードを投稿で再利用するには、ハウスルールに準拠する必要があります。 お気に入りに登録してチャート上でご利用頂けます。

免責事項

これらの情報および投稿は、TradingViewが提供または保証する金融、投資、取引、またはその他の種類のアドバイスや推奨を意図したものではなく、またそのようなものでもありません。詳しくは利用規約をご覧ください。

チャートでこのスクリプトを利用したいですか?
//
// @author LazyBear 
// 
// List of my public indicators: http://bit.ly/1LQaPK8 
// List of my app-store indicators: http://blog.tradingview.com/?p=970 
//

study("Belkhayate Timing [LazyBear]", shorttitle="BT_LB", overlay=false)
showHLC=input(true, title="Smooth Osc?"), showHisto=input(false, title="Show Histogram?")
Range1=input(4), Range2=input(8), ebc=input(false, title="Enable Barcolors")
middle = (((high + low) / 2) + ((high[1] + low[1]) / 2) + ((high[2] + low[2]) / 2) + ((high[3] + low[3]) / 2) + ((high[4] + low[4]) / 2)) / 5
scale = (((high - low) + (high[1] - low[1]) + (high[2] - low[2]) + (high[3] - low[3]) + (high[4] - low[4])) / 5) * 0.2
h = (high - middle) / scale
l = (low - middle) / scale 
o = (open - middle) / scale
c = (close - middle) / scale
ht=showHLC?avg(h, l, c):c
plot(0, title="ZeroLine", color=gray)
l1=plot(Range1, title="SellLine1", color=gray)
l2=plot(Range2, title="SellLine2", color=gray)
l3=plot(-Range1, title="BuyLine1", color=gray)
l4=plot(-Range2, title="BuyLine2", color=gray)
fill(l1,l2,red, title="OBZone"), fill(l3,l4, lime, title="OSZone")
plot(showHisto?ht:na, style=histogram, title="BTOscHistogram", linewidth=1, color=ht>0?green:red) 
plot(ht, style=line, title="BTOsc", linewidth=3, color=gray) 
bc=ht>0?(ht>=Range2?blue:(ht>=Range1?green:lime)):(ht<=-Range2?blue:(ht<=-Range1?maroon:red))
barcolor(ebc?bc:na)
plot(ht, style=linebr, title="BTOsc", linewidth=3, color=gray)