synapticEx

Nebula Advanced Dynamic Support/Resistance

Still I don't know. Maybe it was not the script, but a bug in trading view that seems to appear when one reach the maximum jackpot: http://imgur.com/5FxvjjL
Remover dos scripts favoritos Adicionar aos scripts favoritos
//@version=2
//synapticex.com
study("Nebula", shorttitle="Nebula", overlay=true)
length = input(title="Length", type=integer, defval=20)

fractal(i, type)=>
    f = 0
    if(type == 1 and n>15)
        f := high[i]<high[i-1] and high[i-1]<high[i-2] and high[i-2]>high[i-3] and high[i-3]>high[i-4] ? 1 : 0
    if(type == 2 and n>15)
        f := low[i]>low[i-1] and low[i-1]>low[i-2] and low[i-2]<low[i-3] and low[i-3]<low[i-4] ? 1 : 0
    f
    
h = fractal(5, 1)
l = fractal(5, 2)
hVal =  h ? high[3] : 0
lVal = l ? low[3] : 0

lSum = n>length*2 ? sum(lVal, length) : 0
hSum = n>length*2 ? sum(hVal, length) : 0
lN = n>length*2 ? sum(l, length) : 0
hN = n>length*2 ? sum(h, length) : 0
r = lSum>0 and hSum>0 and lN>0 and hN>0 ? abs((hSum/hN) - (lSum/lN)): 0

hPlus = hVal  and r?hVal+r:na
hMinus = hVal  and r?hVal-r:na
lPlus = lVal  and r?lVal+r:na
lMinus = lVal  and r?lVal-r:na
    
plot(hPlus, "hPlus", color=lime, linewidth=1, style=cross, transp=0, offset =-3, join=false)
plot(hMinus, "hMinus", color=red, linewidth=1, style=cross, transp=0, offset=-3, join=false)

plot(lPlus, "lPlus", color=white, linewidth=1, style=cross, transp=0, offset =-3, join=false)
plot(lMinus, "lMinus", color=fuchsia, linewidth=1, style=cross, transp=0, offset=-3, join=false)
it's very leggy indicator. give signal very late. any way to make it bit fast?
Resposta
Great Stuff.
Resposta
synapticEx karabogerald
thanks
Resposta
Início Rastreador de Fundamentos Rastreador Forex Rastreador de criptomoedas Calendário econômico Como Funciona Recursos gráficos Preços Regras da Casa Moderadores Soluções para sites e corretoras Widgets Soluções em Gráficos Central de Ajuda Solicitação de recurso Blog & Notícias FAQ Wiki Twitter
Perfil Configurações de perfil Conta e cobrança TradingView Coins Meus Tíquetes de Suporte Central de Ajuda Ideias Publicadas Seguidores Seguindo Mensagens Privadas Conversa Deslogar