OPEN-SOURCE SCRIPT
Vol Vahid

// This source code is subject to the terms of the Mozilla Public License 2.0 at mozilla.org/MPL/2.0/
// © amir
//version=5
indicator("Vol Vahid")
[plus,minus,adx]=ta.dmi(14,14)
sw=input.bool(true,'Highlight Ranging/Sideways')
showbarcolor=input.bool(true,'Apply Barcolor')
show_Baseline=input.bool(true,'Show Hull Trend')
rsiLengthInput = input.int(14, minval=1, title="RSI Length1", group="RSI Settings")
rsiLengthInput2 = input.int(28, minval=1, title="RSI Length2", group="RSI Settings")
trendlen= input(title='Hull Trend Length', defval=30,group='Hull Trend')
oversold=input.int(30, minval=1, title="Over Sold", group="RSI Settings")
overbought=input.int(70, minval=1, title="Over Bought", group="RSI Settings")
BBMC=ta.hma(close,trendlen)
MHULL = BBMC[0]
SHULL = BBMC[2]
hmac=MHULL > SHULL ?color.new(#00c3ff , 0):color.new(#ff0062, 0)
buysignal=MHULL > SHULL
sellsignal=MHULL < SHULL
frsi=ta.hma(ta.rsi(close,rsiLengthInput),10)
srsi=ta.hma(ta.rsi(close,rsiLengthInput2),10)
hullrsi1=ta.rsi(MHULL,rsiLengthInput)
hullrsi2=ta.rsi(SHULL,rsiLengthInput)
rsic=frsi>srsi?color.new(#00c3ff , 0):color.new(#ff0062, 0)
barcolor(showbarcolor?hmac:na)
hu1=plot(show_Baseline?hullrsi1:frsi,title='HMA1',color=color.gray,linewidth=1,display=display.none)
hu2=plot(show_Baseline?hullrsi2:srsi,title='HMA2',color=color.gray,linewidth=1,display=display.none)
fill(hu1,hu2,title='HULL RSI TREND',color=show_Baseline?hmac:rsic)
fill(hu1,hu2,title='HULL with Sideways',color=sw and adx<20?color.gray:na)
rsiUpperBand2 = hline(90, "RSI Upper Band(90)", color=color.red,linestyle=hline.style_dotted,display=display.none)
rsiUpperBand = hline(overbought, "RSI Upper Band", color=color.red,linestyle=hline.style_dotted,display=display.none)
fill(rsiUpperBand2,rsiUpperBand,title='Buy Zone',color=color.red,transp=80)
hline(50, "RSI Middle Band", color=color.new(#787B86, 50),linestyle=hline.style_solid)
rsiLowerBand = hline(oversold, "RSI Lower Band", color=color.green,linestyle=hline.style_dotted,display=display.none)
rsiLowerBand2 = hline(10, "RSI Lower Band(10)", color=color.green,linestyle=hline.style_dotted,display=display.none)
fill(rsiLowerBand,rsiLowerBand2,title='Sell Zone',color=color.green,transp=80)
plotshape(buysignal and sellsignal[1] ?hullrsi1 :na, title='Buy', style=shape.triangleup, location=location.absolute, color=color.new(color.yellow, 0), size=size.tiny, offset=0)
plotshape(sellsignal and buysignal[1] ?hullrsi1 :na, title='Sell', style=shape.triangledown, location=location.absolute, color=color.new(color.red, 0), size=size.tiny, offset=0)
alertcondition(buysignal and sellsignal[1] ,title='RSI TREND:Buy Signal',message='RSI TREND: Buy Signal')
alertcondition(sellsignal and buysignal[1],title='RSI TREND:Sell Signal',message='RSI TREND: Sell Signal')
// © amir
//version=5
indicator("Vol Vahid")
[plus,minus,adx]=ta.dmi(14,14)
sw=input.bool(true,'Highlight Ranging/Sideways')
showbarcolor=input.bool(true,'Apply Barcolor')
show_Baseline=input.bool(true,'Show Hull Trend')
rsiLengthInput = input.int(14, minval=1, title="RSI Length1", group="RSI Settings")
rsiLengthInput2 = input.int(28, minval=1, title="RSI Length2", group="RSI Settings")
trendlen= input(title='Hull Trend Length', defval=30,group='Hull Trend')
oversold=input.int(30, minval=1, title="Over Sold", group="RSI Settings")
overbought=input.int(70, minval=1, title="Over Bought", group="RSI Settings")
BBMC=ta.hma(close,trendlen)
MHULL = BBMC[0]
SHULL = BBMC[2]
hmac=MHULL > SHULL ?color.new(#00c3ff , 0):color.new(#ff0062, 0)
buysignal=MHULL > SHULL
sellsignal=MHULL < SHULL
frsi=ta.hma(ta.rsi(close,rsiLengthInput),10)
srsi=ta.hma(ta.rsi(close,rsiLengthInput2),10)
hullrsi1=ta.rsi(MHULL,rsiLengthInput)
hullrsi2=ta.rsi(SHULL,rsiLengthInput)
rsic=frsi>srsi?color.new(#00c3ff , 0):color.new(#ff0062, 0)
barcolor(showbarcolor?hmac:na)
hu1=plot(show_Baseline?hullrsi1:frsi,title='HMA1',color=color.gray,linewidth=1,display=display.none)
hu2=plot(show_Baseline?hullrsi2:srsi,title='HMA2',color=color.gray,linewidth=1,display=display.none)
fill(hu1,hu2,title='HULL RSI TREND',color=show_Baseline?hmac:rsic)
fill(hu1,hu2,title='HULL with Sideways',color=sw and adx<20?color.gray:na)
rsiUpperBand2 = hline(90, "RSI Upper Band(90)", color=color.red,linestyle=hline.style_dotted,display=display.none)
rsiUpperBand = hline(overbought, "RSI Upper Band", color=color.red,linestyle=hline.style_dotted,display=display.none)
fill(rsiUpperBand2,rsiUpperBand,title='Buy Zone',color=color.red,transp=80)
hline(50, "RSI Middle Band", color=color.new(#787B86, 50),linestyle=hline.style_solid)
rsiLowerBand = hline(oversold, "RSI Lower Band", color=color.green,linestyle=hline.style_dotted,display=display.none)
rsiLowerBand2 = hline(10, "RSI Lower Band(10)", color=color.green,linestyle=hline.style_dotted,display=display.none)
fill(rsiLowerBand,rsiLowerBand2,title='Sell Zone',color=color.green,transp=80)
plotshape(buysignal and sellsignal[1] ?hullrsi1 :na, title='Buy', style=shape.triangleup, location=location.absolute, color=color.new(color.yellow, 0), size=size.tiny, offset=0)
plotshape(sellsignal and buysignal[1] ?hullrsi1 :na, title='Sell', style=shape.triangledown, location=location.absolute, color=color.new(color.red, 0), size=size.tiny, offset=0)
alertcondition(buysignal and sellsignal[1] ,title='RSI TREND:Buy Signal',message='RSI TREND: Buy Signal')
alertcondition(sellsignal and buysignal[1],title='RSI TREND:Sell Signal',message='RSI TREND: Sell Signal')
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.