vdubus

Vdub_Tetris_Stoch_V1

Vdub_Tetris_Stoch_V1
A combination lower based indicators based on the period channel indicator Vdub_Tetris_V2 Blue line is more reactive fast moving, Red line in more accurate to highs / Lows with divergence.- Still testing
Code title error
Change % = Over Bought / Over Sold
Vdub Tetris_V2
Vdubus BinaryPro 2 /Tops&Bottoms
StochDM

Skript med en öppen källkod

I sann TradingView-anda har författaren publicerat detta skript med öppen källkod så att andra handlare kan förstå och verifiera det. Hatten av för författaren! Du kan använda det gratis men återanvändning av den här koden i en publikation regleras av våra ordningsregler. Du kan ange den som favorit för att använda den i ett diagram.

Frånsägelse av ansvar

Informationen och publikationerna är inte avsedda att vara, och utgör inte heller finansiella, investerings-, handels- eller andra typer av råd eller rekommendationer som tillhandahålls eller stöds av TradingView. Läs mer i Användarvillkoren.

Vill du använda det här skriptet i ett diagram?
study(title="Vdub_Tetris_Stoch_V1", shorttitle="Vdub_Tetris_SV1", overlay=false)
//Modified script for binary Options trading ="Vdubus BinaryPro 2"
//.Original PPO Code Created by TheLark / Chris Moody
// Tops & Bottoms.
pctile = input(90, title="Over_Bought")
wrnpctile = input(70, title=" Over_Sold")
Short = input(0.3, title="LONG")
Long = input(0.5, title="SHORT")
lkbT = input(250,title="'PRO-Top")
lkbB = input(250,title="'PRO-Bottom")
//sl=input(true)
//swl=input(true)
//Laguerre PPO Code from TheLark
lag(g, p) =>
    L0 = (1 - g)*p+g*nz(L0[1])
    L1 = -g*L0+nz(L0[1])+g*nz(L1[1])
    L2 = -g*L1+nz(L1[1])+g*nz(L2[1])
    L3 = -g*L2+nz(L2[1])+g*nz(L3[1])
    f = (L0 + 2*L1 + 2*L2 + L3)/6
    f
lmas = lag(Short, hl2)
lmal = lag(Long, hl2)

pctileB = pctile * -1
wrnpctileB = wrnpctile * -1

//PPO Plot
ppoT = (lmas-lmal)/lmal*100
ppoB = (lmal - lmas)/lmal*100
//PercentRank of PPO 
pctRankT = percentrank(ppoT, lkbT)
pctRankB = percentrank(ppoB, lkbB) * -1
//Color Definition of Columns
colT = pctRankT >= pctile ? red : pctRankT >= wrnpctile and pctRankT < pctile ? red : red
plot(pctRankT,title="Percentile Rank Columns", color=colT, style=line, linewidth=2)
//-------------------------------------------
//Original coding Khramov.Vladislav*StochDMI*AWESOME*5 min binary options*
wwma(l,p) =>
    wwma = (nz(wwma[1]) * (l - 1) + p) / l

DMIlength = input(10, title = "DMI")
Stolength = input(6, title = "DMI Stoch")
os = input (15, title = "%")
ob = input (85, title = "%")

hiDiff = high - high[1]
loDiff = low[1] - low

plusDM = (hiDiff > loDiff) and (hiDiff > 0) ? hiDiff : 0
minusDM = (loDiff > hiDiff) and (loDiff > 0) ? loDiff : 0

ATR = wwma(DMIlength, tr)

PlusDI = 100 * wwma(DMIlength,plusDM) / ATR
MinusDI = 100 * wwma(DMIlength,minusDM) / ATR

osc = PlusDI - MinusDI

hi = highest(osc, Stolength)
lo = lowest(osc, Stolength)

Stoch = sum((osc-lo),Stolength) / sum((hi-lo),Stolength) *100
plot(Stoch, color = blue, title = 'Stochastic', linewidth = 1, style = line)

crossUp = Stoch[1] < os and Stoch > os ? 1 : 0
crossDo = Stoch[1] > ob and Stoch < ob ? 1 : 0

plotshape(crossUp, title="Arror up", style=shape.triangleup, location=location.bottom, color=red)
plotshape(crossDo, title="Arrow down",style=shape.triangledown, location=location.top, color=green)

line2 = hline(80, linestyle=solid, color=green, linewidth = 2)
//line1 = hline(50, color=blue)
line0 = hline(20, linestyle=solid, color=red, linewidth = 2)
fill(line2, line0, transp=90)
//========================================================================================= 
//---Vdub Tetris
Sml_Channel_TF_mins_D_W_M = input("720")
Range = input(1)

SELL = security(tickerid, Sml_Channel_TF_mins_D_W_M, highest(Range))
BUY = security(tickerid, Sml_Channel_TF_mins_D_W_M, lowest(Range))

Hcon = high >= SELL
Lcon = low <= BUY
range = SELL-BUY
//--------------------------------------------------
Lrg_Channel_TF_mins_D_W_M = input('D')
M_HIGH = security(tickerid, Lrg_Channel_TF_mins_D_W_M, high)
M_LOW = security(tickerid, Lrg_Channel_TF_mins_D_W_M, low)
//--------------------------------------------------
length = input(4)
hls = rma(hl2, length)
isRising = hls >= hls[1]

zigzag1 = isRising and not isRising[1] ? lowest(length) :  not isRising and isRising[1] ? highest(length) : na
//========================bgcolor=================================
bgcolor(Hcon >= Lcon ? #FFFFFF : #0000FF, transp=90)
bgcolor(Lcon >= Hcon ? #FFFFFF : #9771C5, transp=80)
//--------------------------
//======================================================================================================