この戦略は,市場動向を識別するためにビットコインの真の強さ指数 (True Strength Index,TSI) を計算し,RSI指数フィルターと組み合わせて多額の空調をすることで,ビットコインのショートライン取引を実現します.この戦略は,ビットコイン市場での手書きによる手続き的な取引を行う投資家にとって適しています.
この戦略は,主に実力強弱指標 ((TSI) をベースとしている.TSI指標は,価格変化の絶対値の大きさと方向を,双平滑の価格変化率で測定し,価格上昇と下落の絶対力を識別する.具体的計算方法は以下のとおりである.
TSI指標の上の信号線tsi2を横断すると多信号が発生し,信号線tsi2を横断すると空白信号が発生する.また,戦略は,RSI指標のTSI取引信号のフィルタリングと組み合わせて,RSI値が50以上の場合のみ多信号が発生し,RSI値が50未満の場合は空白信号が発生し,偽信号の一部をフィルタリングする.
この戦略の利点は以下の通りです.
この戦略には以下のリスクもあります.
RSIフィルタリング条件を適切に緩和し,EMAサイクルを短縮することによって,波動効果と滞り問題を軽減することができます.同時に,ストップ・ローズ戦略を最適化し,単一取引のリスクを厳格に制御します.
この戦略は以下の点で最適化できます.
TSIとRSIのパラメータを最適化して,最適なパラメータの組み合わせを見つけます.長いEMA周期,RSIパラメータなど調整できます.
他の指標を組み合わせて,多因数モデルを形成する.例えば,MA,KDなどの指標を加えることができ,各指標の優位性を十分に発揮する.
入場条件を最適化し,多頭市が空頭と空頭市が多頭とぶつからないようにする.大周期的な傾向に基づいて方向を判断することができる.
モバイルストップ,タイムストップ,ストップを突破するなど,ストップ戦略の最適化.
離場条件を最適化して,早すぎたり遅すぎたりして離場を防ぐ. 離場を判断する際には,波動率指標と組み合わせることができる.
取引品種と取引時期を最適化し,最も有効な品種と取引時に集中する.
この戦略は,実際の強み指標によってビットコインの短期トレンドを識別し,RSI指標のフィルタリング信号に補足し,ビットコインのショートラインプログラム取引を効果的に行うことができます. この戦略は,傾向を感知し,ノイズを排除する利点がありますが,一定の遅れの問題と取引リスクもあります. 多方面での最適化により,戦略のパフォーマンスをさらに向上させ,信頼できるビットコイン取引専門家アドバイザーを開発できます.
/*backtest
start: 2022-09-30 00:00:00
end: 2023-10-06 00:00:00
period: 1d
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
// strategy("True Strength Indicator BTCUSD 15p", shorttitle="TSI BTCUSD 15p",initial_capital=1000, commission_value=0.15, commission_type =strategy.commission.percent, default_qty_value=100 , overlay = false, pyramiding=10, default_qty_type=strategy.percent_of_equity)
//BASED ON True Strength Indicator MTF
resCustom = input(title="Timeframe", defval="15" )
long = input(title="Long Length", defval=25)
short = input(title="Short Length", defval=13)
signal = input(title="Signal Length", defval=13)
price = request.security(syminfo.tickerid,resCustom,close)
double_smooth(src, long, short) =>
fist_smooth = ta.ema(src, long)
ta.ema(fist_smooth, short)
pc = ta.change(price)
double_smoothed_pc = double_smooth(pc, long, short)
double_smoothed_abs_pc = double_smooth(math.abs(pc), long, short)
tsi_value = 100 * (double_smoothed_pc / double_smoothed_abs_pc)
tsi2=ta.ema(tsi_value, signal)
plot(tsi_value, color=color.lime,linewidth=2)
plot(tsi2, color=color.red,linewidth=2)
rsiserie = ta.rsi(price,7)
cciserie = ta.cci(price,14)
stochserie = ta.stoch(price,14,3,3)
plot(rsiserie,color=color.purple)
hline(30, title="Zero")
hline(50, title="Zero",linestyle=hline.style_solid, linewidth=2)
hline(70, title="Zero")
buy = ta.crossover(tsi_value, tsi2) //and rsiserie[1]<25 //and cciserie<-100 and stochserie<20
sell = ta.crossunder(tsi_value, tsi2) //and rsiserie[1]>85 //and cciserie>100 and stochserie>80
alertcondition(buy, title='TSI system', message='Buy signal at!' )
alertcondition(sell, title='TSI system', message='Sell signal at!' )
strategy.entry("BUY", strategy.long, 1, when = buy)
strategy.entry("SELL", strategy.short, 1, when = sell )
greentsi =tsi_value
redtsi = tsi2
bgcolor( greentsi>redtsi and rsiserie > 50 ? color.lime : na, transp=90)
bgcolor( greentsi<redtsi and rsiserie < 50 ? color.red : na, transp=90)
yellow1= redtsi > greentsi and rsiserie > 50
yellow2 = redtsi < greentsi and rsiserie < 50
bgcolor( yellow1 ? yellow : na, transp=80)
bgcolor( yellow2 ? yellow : na, transp=50)
bgcolor( yellow1 and yellow1[1] ? yellow : na, transp=70)
bgcolor( yellow2 and yellow2[2] ? yellow : na, transp=70)
bgcolor( rsiserie > 70 ? color.lime : na, transp=60)
bgcolor( rsiserie < 30 ? color.red : na, transp=60)