この記事では,ダイナミックな価格チャネルに基づくショートライン取引戦略について説明します. この戦略は,価格のダイナミックなチャネルを計算してトレンドの方向を判断し,チャネルの突破点で取引します.
この戦略は以下の原則に基づいています.
最高価格と最低価格を使用して動的価格チャネルを計算する.チャネルの上線は最高価格とチャネルの中線の合計の半分,下線は最低価格とチャネルの中線の差の半分である.
価格が上線を突破すると,上向きのトレンドに入っていることを示し,価格が下線を突破すると,下向きのトレンドに入っていることを示します.
上向きのトレンドでは,連続した陰線が2つ現れる時に多めにします. 下向きのトレンドでは,連続した陽線が2つ現れる時に空いてください.
市場情勢を把握するために,上昇時に空白し,下落時に多額の取引を行うことができます.
ストップポイントを入場価格のx%に設定して,利益をロックするなど,ストップポイントの割合を設定できます.
この戦略の利点は以下の通りです.
ダイナミックチャネルは,市場の変化をリアルタイムで反映し,トレンドを判断する上で役立ちます.
トレンドといくつかのK線の突破信号を組み合わせて,偽突破をフィルターすることができます.
逆のポジションは,市場の熱点に追いついて,余分な利益を得ることができます.
リスクの管理に有効である.
戦略はシンプルでわかりやすく,実行しやすい.
この戦略にはリスクもあります.
市場が激しく波動すると,通路は機能しなくなります.通路をより安定させるためにパラメータを適切に調整する必要があります.
逆転ポジションは損益に弱いので,単価の損益比率をコントロールするべきである.
偽の突破は誤った取引につながる可能性がある. 突破の有効性を判断するには,トレンドと組み合わせる必要があります.
取引コストをコントロールするために,頻繁に取引を避けるように注意してください.
この戦略は,ダイナミックな通路判断の傾向,K線突破の入場,およびストップ思考を統合している.パラメータの調整が適切である場合,ショートライン取引の有効なツールとして使用することができる.しかし,トレーダーはリスク管理に注意を払い,自分の取引スタイルに合わせて適切な変更を行う必要があります.
/*backtest
start: 2022-09-09 00:00:00
end: 2023-09-15 00:00:00
period: 2d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=2
strategy("Noro's Bands Scalper Strategy v1.1", shorttitle = "Scalper str 1.1", overlay=true, default_qty_type = strategy.percent_of_equity, default_qty_value=100.0, pyramiding=0)
//Settings
needlong = input(true, defval = true, title = "Long")
needshort = input(true, defval = true, title = "Short")
takepercent = input(0, defval = 0, minval = 0, maxval = 1000, title = "take, %")
needct = input(false, defval = false, title = "Counter-trend entry")
len = input(20, defval = 20, minval = 2, maxval = 200, title = "Period")
needbb = input(true, defval = true, title = "Show Bands")
needbg = input(true, defval = true, title = "Show Background")
src = close
//PriceChannel
lasthigh = highest(src, len)
lastlow = lowest(src, len)
center = (lasthigh + lastlow) / 2
//Distance
dist = abs(src - center)
distsma = sma(dist, len)
hd = center + distsma
ld = center - distsma
hd2 = center + distsma * 2
ld2 = center - distsma * 2
//Trend
sma = sma(close, 20)
smatrend = close > sma ? 1 : close < sma ? -1 : smatrend[1]
trend = close < ld and high < hd ? -1 : close > hd and low > ld ? 1 : trend[1]
//Lines
colo = needbb == false ? na : black
plot(hd, color = colo, linewidth = 1, transp = 0, title = "High band")
plot(center, color = colo, linewidth = 1, transp = 0, title = "center")
plot(ld, color = colo, linewidth = 1, transp = 0, title = "Low band")
//Background
col = needbg == false ? na : trend == 1 ? lime : red
bgcolor(col, transp = 80)
//Signals
bar = close > open ? 1 : close < open ? -1 : 0
up7 = trend == 1 and bar == -1 and bar[1] == -1 ? 1 : 0
dn7 = trend == 1 and bar == 1 and bar[1] == 1 and close > strategy.position_avg_price * (100 + takepercent) / 100 ? 1 : 0
up8 = trend == -1 and bar == -1 and bar[1] == -1 and close < strategy.position_avg_price * (100 - takepercent) / 100 ? 1 : 0
dn8 = trend == -1 and bar == 1 and bar[1] == 1 ? 1 : 0
if up7 == 1 or up8 == 1
strategy.entry("Long", strategy.long, needlong == false ? 0 : trend == -1 and needct == false ? 0 : na)
if dn7 == 1 or dn8 == 1
strategy.entry("Short", strategy.short, needshort == false ? 0 : trend == 1 and needct == false ? 0 : na)