This strategy combines the Hull Moving Average and Ichimoku Kinko Hyo indicators to implement a trend-following trading system. The system can capture medium-term trends for trend trading.
This strategy uses the Hull Moving Average to determine the direction of the price trend. The Hull MA is an optimized version of the moving average that can respond more quickly to price changes. The strategy here employs a triple Hull MA system, containing 6-period, 3-period and 1.5-period Hull MAs.
In addition, the strategy also incorporates the Ichimoku Kinko Hyo conversion and lagging span lines. These two indicators reflect the medium to long term trend of the prices. The strategy combines the triple Hull MA and Ichimoku indicators to generate trading signals.
Specifically, the strategy calculates the triple Hull MA: n1, n2, n2ma. As well as two Ichimoku indicators: leadLine1 and leadLine2. It then computes post1 and post2 as the final trading metrics.
When post1 crosses over post2 upward, go long. When post1 crosses below post2, go short. This allows us to track and capture price medium-term trends for trend trading.
The advantages of this strategy include:
There are also some risks with this strategy:
Countermeasures:
This strategy can also be improved in the following aspects:
This strategy combines the Hull MA and Ichimoku Kinko Hyo indicators to build a simple and practical trend following system. With fast responses, it can effectively capture medium-term price trends. Further testing and optimization, through parameter tuning and adding filters, can lead to better trading performance. ]
/*backtest start: 2023-12-17 00:00:00 end: 2023-12-24 00:00:00 period: 30m basePeriod: 15m exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}] */ //@version=3 // HULL & ICHIMOKU & MATHS strategy("3 HULLs & ICHIMOKU divided by PRICE", shorttitle="3H&I/P", overlay=true, default_qty_type=strategy.percent_of_equity, max_bars_back=720, default_qty_value=100, calc_on_order_fills=true, calc_on_every_tick=true, pyramiding=0) keh=input(title="Hull MA period",defval=6) p=ohlc4[1] n2ma=2*wma(p,round(keh/2)) nma=wma(p,keh) diff=n2ma-nma sqn=round(sqrt(keh)) n2ma1=2*wma(p[1],round(keh/2)) nma1=wma(p[1],keh) diff1=n2ma1-nma1 sqn1=round(sqrt(keh)) n1=wma(diff,sqn) n2=wma(diff1,sqn) conversionPeriods = input(9, minval=1, title="Conversion Line Periods") basePeriods = input(26, minval=1, title="Base Line Periods") laggingSpan2Periods = input(52, minval=1, title="Lagging Span 2 Periods") displacement = input(26, minval=1, title="Displacement") donchian(len) => avg(lowest(len), highest(len)) conversionLine = donchian(conversionPeriods) baseLine = donchian(basePeriods) leadLine1 = avg(conversionLine, baseLine) leadLine2 = donchian(laggingSpan2Periods) post1=((n1[1]*3)+leadLine1)/p post2=((n2[1]*3)+leadLine2)/p if (post1<post2) strategy.entry("buy", strategy.long, comment="BUY") if (post1>post2) strategy.entry("sell", strategy.short, comment="SELL")