TradingView
SeaSide420
16 de Nov de 2018 03:17

Hull_TSI Strategy v3 

Ethereum / DollarBitfinex

Descrição

True Strength Index, but Exponential Moving Average taken out and replaced with Hull Moving Average
this version uses 3 Hull MA's as well as the TSI value crossovers above or below the upper/lower lines
This version is the closest to the API bot featured at gekkoplus.com
Hull_TSI bot is competing in the competition
" Gekko Plus is hosting a strategy contest. Submit the best performing Gekko strategy and win 0.1 BTC! "

15 Nov 2018: Strategy contest start
10 Dec 2018: Strategy contest end
12 Dec 2018: Contest evaluation, announcement of winners!
Comentários
mosh720
Hello, Would you share the Open Code on this ?
SeaSide420
@mosh720,
//@version=3 strategy("Hull_TSI Strategy v3",commission_type=strategy.commission.percent, commission_value=0.075, default_qty_type=strategy.percent_of_equity, max_bars_back=200, default_qty_value=100, calc_on_order_fills= true, calc_on_every_tick=true) z1=input(title="Hull Short Length", type=integer,defval=130) z2=input(title="Hull Mid Length", type=integer,defval=140) z3=input(title="Hull Long Length", type=integer,defval=150) long = input(title="Long Length", type=integer, defval=420) short = input(title="Short Length", type=integer, defval=420) signal = input(title="Signal Length", type=integer, defval=32) linebuy = input(title="Upper Line", type=integer, defval=10) linesell = input(title="Lower Line", type=integer, defval=-10) FromMonth = input(defval = 1, title = "From Month", minval = 1, maxval = 12) FromDay = input(defval = 1, title = "From Day", minval = 1, maxval = 31) FromYear = input(defval = 2018, title = "From Year", minval = 2017) ToMonth = input(defval = 1, title = "To Month", minval = 1, maxval = 12) ToDay = input(defval = 1, title = "To Day", minval = 1, maxval = 31) ToYear = input(defval = 9999, title = "To Year", minval = 2017) start = timestamp(FromYear, FromMonth, FromDay, 00, 00) finish = timestamp(ToYear, ToMonth, ToDay, 23, 59) window() => time >= start and time <= finish ? true : false price = input(ohlc4,type=source) func_hma(style, length)=> return = wma((2 * wma(style, length / 2)) - wma(style, length), round(sqrt(length))) double_smooth(price, long, short) => fist_smooth = func_hma(price, long) func_hma(fist_smooth, short) pc = change(price) double_smoothed_pc = double_smooth(pc, long, short) double_smoothed_abs_pc = double_smooth(abs(pc), long, short) tsi_value = 100 * (double_smoothed_pc / double_smoothed_abs_pc) keh = tsi_value>linesell?lime:orange teh = func_hma(tsi_value, signal)>linebuy?orange:red meh = func_hma(tsi_value, signal)>tsi_value?red:lime plot(tsi_value, color=keh, linewidth=2) plot(func_hma(tsi_value, signal), color=teh, linewidth=2) plot(linebuy,color=green),plot(linesell,color=red) plot(cross(tsi_value, func_hma(tsi_value, signal)) ? tsi_value : na, style = circles, color=meh, linewidth = 3) longCondition = tsi_value>func_hma(tsi_value, signal) and tsi_value<linesell shortCondition = tsi_value<func_hma(tsi_value, signal) and tsi_value>linebuy hullup = func_hma(price, z1)>func_hma(price, z2) and func_hma(price, z2)>func_hma(price, z3) hulldown = func_hma(price, z1)<func_hma(price, z2) and func_hma(price, z2)<func_hma(price, z3) if (hullup and longCondition) strategy.entry("BUY", strategy.long, when=window()) if (hulldown and shortCondition) strategy.entry("SELL", strategy.short, when=window())
mosh720
@SeaSide420, Hey bud thank you. I also was looking at the Hull_TSI v 420 .... I'm trying to figure out the repainting issue. Can you share that Script as well. I want to work with you on this and improve them and i think they are great Starts
Mais