Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //@version=3
- study(title='E', overlay=true)
- labels = input(true, title='LABELS')
- crosses = input(false, title='CROSSES')
- gdcross = input(true, title='G&D CROSS')
- ogdcross = input(false, title='OTHER G&D')
- dailies = input(false, title='DAILY EMAS')
- hideo = input(false, title='HIDE OTHERS')
- sma10 = sma(close, 10)
- plot(hideo == false ? sma10:na, color=red, transp=0, linewidth=1, title='10')
- ema21 = ema(close, 21)
- plot(hideo == false ? ema21:na, color=yellow, transp=0, linewidth=2, title='21')
- ema50 = ema(close, 50)
- plot(hideo == false ? ema50:na, color=lime, transp=0, linewidth=2, title='50')
- ema89 = ema(close, 89)
- plot(hideo == false ? ema89:na, color=#e91e63, transp=0, linewidth=2, title='89')
- ema100 = ema(close, 100)
- plot(hideo == false ? ema100:na, color=aqua, transp=0, linewidth=2, title='100')
- ema144 = ema(close, 144)
- plot(hideo == false ? ema144:na, color=#512da8, transp=0, linewidth=2, title='144')
- ema200 = ema(close, 200)
- plot(hideo == false ? ema200:na, color=fuchsia, transp=0, linewidth=2, title='200')
- sma200 = sma(close, 200)
- plot(hideo == false ? sma200:na, color=red, transp=0, linewidth=2, title='200')
- ema377 = ema(close, 377)
- plot(hideo == false ? ema377:na, color=maroon, transp=0, linewidth=2, title='377')
- ema886 = ema(close, 886)
- plot(hideo == false ? ema886:na, color=white, transp=0, linewidth=2, title='886')
- sma10_1d = security(tickerid, 'D', sma10)
- plot(dailies == true ? sma10_1d:na, color=red, transp=0, linewidth=1, title='10 D')
- ema21_1d = security(tickerid, 'D', ema21)
- plot(dailies == true ? ema21_1d:na, color=yellow, transp=0, linewidth=2, title='21 D')
- ema50_1d = security(tickerid, 'D', ema50)
- plot(dailies == true ? ema50_1d:na, color=lime, transp=0, linewidth=2, title='50 D')
- ema89_1d = security(tickerid, 'D', ema89)
- plot(dailies == true ? ema89_1d:na, color=#e91e63, transp=0, linewidth=2, title='89 D')
- ema100_1d = security(tickerid, 'D', ema100)
- plot(dailies == true ? ema100_1d:na, color=aqua, transp=0, linewidth=2, title='100 D')
- ema144_1d = security(tickerid, 'D', ema144)
- plot(dailies == true ? ema144_1d:na, color=#512da8, transp=0, linewidth=2, title='144 D')
- ema200_1d = security(tickerid, 'D', ema200)
- plot(dailies == true ? ema200_1d:na, color=fuchsia, transp=0, linewidth=2, title='200 D')
- sma200_1d = security(tickerid, 'D', sma200)
- plot(dailies == true ? sma200_1d:na, color=red, transp=0, linewidth=2, title='200 D')
- ema377_1d = security(tickerid, 'D', ema377)
- plot(dailies == true ? ema377_1d:na, color=maroon, transp=0, linewidth=2, title='377 D')
- ema886_1d = security(tickerid, 'D', ema886)
- plot(dailies == true ? ema886_1d:na, color=white, transp=0, linewidth=2, title='886 D')
- sma10_cu = crossunder(close, sma10)
- sma10_co = crossover(close, sma10)
- plotshape(hideo == false and crosses == true ? sma10_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=red, transp=0, title='10', size=size.tiny)
- plotshape(hideo == false and crosses == true ? sma10_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=red, transp=0, title='10', size=size.tiny)
- plotshape(hideo == false and labels == true ? sma10:na, style=shape.diamond, location=location.absolute, show_last=1, color=red, transp=0, text='10', title='10', offset=4)
- ema21_cu = crossunder(close, ema21)
- ema21_co = crossover(close, ema21)
- plotshape(hideo == false and crosses == true ? ema21_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=yellow, transp=0, title='21', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema21_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=yellow, transp=0, title='21', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema21:na, style=shape.diamond, location=location.absolute, show_last=1, color=yellow, transp=0, text='21', title='21', offset=4)
- ema50_cu = crossunder(close, ema50)
- ema50_co = crossover(close, ema50)
- plotshape(hideo == false and crosses == true ? ema50_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=lime, transp=0, title='50', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema50_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=lime, transp=0, title='50', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema50:na, style=shape.diamond, location=location.absolute, show_last=1, color=lime, transp=0, text='50', title='50', offset=4)
- ema89_cu = crossunder(close, ema89)
- ema89_co = crossover(close, ema89)
- plotshape(hideo == false and crosses == true ? ema89_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=#e91e63, transp=0, title='89', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema89_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=#e91e63, transp=0, title='89', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema89:na, style=shape.diamond, location=location.absolute, show_last=1, color=#e91e63, transp=0, text='89', title='89', offset=4)
- ema100_cu = crossunder(close, ema100)
- ema100_co = crossover(close, ema100)
- plotshape(hideo == false and crosses == true ? ema100_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=aqua, transp=0, title='100', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema100_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=aqua, transp=0, title='100', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema100:na, style=shape.diamond, location=location.absolute, show_last=1, color=aqua, transp=0, text='100', title='100', offset=4)
- ema144_cu = crossunder(close, ema144)
- ema144_co = crossover(close, ema144)
- plotshape(hideo == false and crosses == true ? ema144_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=#512da8, transp=0, title='144', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema144_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=#512da8, transp=0, title='144', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema144:na, style=shape.diamond, location=location.absolute, show_last=1, color=#512da8, transp=0, text='144', title='144', offset=4)
- ema200_cu = crossunder(close, ema200)
- ema200_co = crossover(close, ema200)
- plotshape(hideo == false and crosses == true ? ema200_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=fuchsia, transp=0, title='200', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema200_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=fuchsia, transp=0, title='200', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema200:na, style=shape.diamond, location=location.absolute, show_last=1, color=fuchsia, transp=0, text='200', title='200', offset=4)
- sma200_cu = crossunder(close, sma200)
- sma200_co = crossover(close, sma200)
- plotshape(hideo == false and crosses == true ? sma200_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=red, transp=0, title='200', size=size.tiny)
- plotshape(hideo == false and crosses == true ? sma200_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=red, transp=0, title='200', size=size.tiny)
- plotshape(hideo == false and labels == true ? sma200:na, style=shape.diamond, location=location.absolute, show_last=1, color=red, transp=0, text='200', title='200', offset=4)
- ema377_cu = crossunder(close, ema377)
- ema377_co = crossover(close, ema377)
- plotshape(hideo == false and crosses == true ? ema377_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=maroon, transp=0, title='377', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema377_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=maroon, transp=0, title='377', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema377:na, style=shape.diamond, location=location.absolute, show_last=1, color=maroon, transp=0, text='377', title='377', offset=4)
- ema886_cu = crossunder(close, ema886)
- ema886_co = crossover(close, ema886)
- plotshape(hideo == false and crosses == true ? ema886_cu:na, style=shape.xcross, location=location.belowbar, show_last=1, color=white, transp=0, title='886', size=size.tiny)
- plotshape(hideo == false and crosses == true ? ema886_co:na, style=shape.xcross, location=location.abovebar, show_last=1, color=white, transp=0, title='886', size=size.tiny)
- plotshape(hideo == false and labels == true ? ema886:na, style=shape.diamond, location=location.absolute, show_last=1, color=white, transp=0, text='886', title='886', offset=4)
- plotshape(dailies == true and labels == true ? sma10_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=red, transp=0, text='10 D', title='10 D', offset=8)
- plotshape(dailies == true and labels == true ? ema21_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=yellow, transp=0, text='21 D', title='21 D', offset=8)
- plotshape(dailies == true and labels == true ? ema50_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=lime, transp=0, text='50 D', title='50 D', offset=8)
- plotshape(dailies == true and labels == true ? ema89_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=#e91e63, transp=0, text='89 D', title='89 D', offset=8)
- plotshape(dailies == true and labels == true ? ema100_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=aqua, transp=0, text='100 D', title='100 D', offset=8)
- plotshape(dailies == true and labels == true ? ema144_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=#512da8, transp=0, text='144 D', title='144 D', offset=8)
- plotshape(dailies == true and labels == true ? ema200_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=fuchsia, transp=0, text='200 D', title='200 D', offset=8)
- plotshape(dailies == true and labels == true ? sma200_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=red, transp=0, text='200 D', title='200 D', offset=8)
- plotshape(dailies == true and labels == true ? ema377_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=maroon, transp=0, text='377 D', title='377 D', offset=8)
- plotshape(dailies == true and labels == true ? ema886_1d:na, style=shape.diamond, location=location.absolute, show_last=1, color=white, transp=0, text='886 D', title='886 D', offset=8)
- goldenx = crossover(ema50, ema200) and not isweekly and not ismonthly
- alertcondition(goldenx, title='GOLDEN X', message='GOLDEN X')
- plotshape(ogdcross == true ? goldenx:na, style=shape.xcross, location=location.belowbar, color=yellow, transp=0, text='G', title='GOLDEN X', show_last=100, size=size.small)
- deathx = crossunder(ema50, ema200) and not isweekly and not ismonthly
- alertcondition(deathx, title='DEATH X', message='DEATH X')
- plotshape(ogdcross == true ? deathx:na, style=shape.xcross, location=location.abovebar, color=red, transp=0, text='D', title='DEATH X', show_last=100, size=size.small)
- goldenx_1d = crossover(ema50_1d, ema200_1d) and not isweekly and not ismonthly
- alertcondition(goldenx_1d, title='1D GOLDEN X', message='1D GOLDEN X')
- plotshape(gdcross == true ? goldenx_1d:na, style=shape.xcross, location=location.belowbar, color=yellow, transp=0, text='1D GOLDEN', title='1D GOLDEN X', show_last=100, size=size.huge)
- deathx_1d = crossunder(ema50_1d, ema200_1d) and not isweekly and not ismonthly
- alertcondition(deathx_1d, title='1D DEATH X', message='1D DEATH X')
- plotshape(gdcross == true ? deathx_1d:na, style=shape.xcross, location=location.abovebar, color=red, transp=0, text='1D DEATH', title='1D DEATH X', show_last=100, size=size.huge)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement