jjaskulowski

Gaussbot v1.0

596 5 74
Gaussbot in action. No repaint, based on open price.
Remove from Favorite Scripts Add to Favorite Scripts
//@version=2
strategy("Gaussbot v1.0", overlay=true)

p = input(20, minval=1, title="Length")
price = input(open, title="Source")

pi=3.1415926535


w=2*pi/p
beta = (1 - cos(w))/(pow(1.414,2.0/3) - 1)
alfa = -beta + sqrt(beta*beta + 2*beta)
ret=  pow(alfa,4)*price+4*(1-alfa)*nz(ret[1])-6*pow(1-alfa,2)*nz(ret[2])+4*pow(1-alfa,3)*nz(ret[3])-pow(1-alfa,4)*nz(ret[4])
ret2 = pow(alfa,4)*ret+4*(1-alfa)*nz(ret2[1])-6*pow(1-alfa,2)*nz(ret2[2])+4*pow(1-alfa,3)*nz(ret2[3])-pow(1-alfa,4)*nz(ret2[4])
ret3 = pow(alfa,4)*ret2+4*(1-alfa)*nz(ret3[1])-6*pow(1-alfa,2)*nz(ret3[2])+4*pow(1-alfa,3)*nz(ret3[3])-pow(1-alfa,4)*nz(ret3[4])
ret4 = 3*ret-3*ret2+ret3


diff2 = nz(ret[1]) - nz(ret[2]) - (nz(ret[2]) - nz(ret[3]) )  
diff22 = nz(ret2[1]) - nz(ret2[2]) - (nz(ret2[2]) - nz(ret2[3]) ) 
diff23 = nz(ret3[1]) - nz(ret3[2]) - (nz(ret3[2]) - nz(ret3[3]) )  
diff24 = nz(ret4[1]) - nz(ret4[2]) - (nz(ret4[2]) - nz(ret4[3]) )  


longCondition =    price[0] - ret4[1]  > 0
shortCondition =  price[0] - ret4[1] < 0

if(longCondition and shortCondition)
    longCondition = longCondition[1]
    shortCondition = shortCondition[1]
if(longCondition==false and shortCondition==false)
    longCondition = longCondition[1]
    shortCondition = shortCondition[1]



if (longCondition==true and shortCondition == false) 
    strategy.entry("Gaussbot Long", strategy.long )
if (longCondition==false and shortCondition == true)
    strategy.entry("Gaussbot Short", strategy.short)

wrety
6 months ago
Hey, nice profit! Is it possible to receive an alerts when the script makes a trade?
Reply
UrbiGT
6 months ago
Heiken ashi ...
Reply
jjaskulowski
6 months ago
I will port indicators from mt4 to tv for bitcoin. Name your price and indicator on priv
Reply
shev72 PRO
6 months ago
can you add a few comments saying what the script is doing? It seems to work well, but I don't really understand the calculations it is doing....
Reply
bitlokal
6 months ago
work well as i test with small amount of muhnay, would be please if you add configuration on the calculation for smaller timeframe ? because positive profit ration work only on 30min and 4hr, on normal candle, heiken ashi is delusional for btc i think. because the graph is squeeze type. ty for sharing sir
Reply
Ideas Scripts Chart
United States
United Kingdom
India
España
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Billing Sign Out