モメント トラッキング トレーディング戦略

作者: リン・ハーンチャオチャン開催日:2023年12月20日 16:06:26
タグ:

img

戦略の概要

モメント・トラッキング・トレーディング・ストラテジー (Momentum Tracking Trading Strategy) は,主に市場のモメント・トレンドを追跡し,複数の技術指標を補助判断として使用する自動化トレーディング・ストラテジーである.この戦略は,現在の市場のメインファンドの方向性と強さを決定するためにK線情報を解析し,その後,ボリューム価格や移動平均などの指標に基づいてトレード・シグナルを発行し,トレンド・トラッキングを達成する.

この戦略は,中長期トレンド取引に適しており,市場のトレンドを効果的に把握し,単一の利益を追求するために取引頻度を減らすことができます.同時に,戦略パラメータを最適化した後,短期取引にも使用できます.

戦略原則

主権判断

モメントトラッキング戦略の核心は,市場の主要ファンドの方向性を判断することである.この戦略は,市場変動をリアルタイムに監視するためにATR指標を計算する.変動が増加すると,主要ファンドが蓄積または分配していることを意味し,戦略は,主要ファンドが運用している期間を避けるために一時的に市場を退場する.

波動性が低下すると,主要フォースの蓄積またはアロケーションが完了し,戦略は主要フォースの特定の方向性を決定するために市場に戻る.判断方法は,突破の兆候があるかどうかを確認するために市場のサポートとプレッシャーポジションを計算することです.明確な突破がある場合は,主要なファンドがその方向性を選択したことを証明します.

補助判決

主要な資金の方向性を決定した後,戦略は誤った判断を避けるため,再度検証するための複数の補助技術指標も導入する.特に,MACD,KDJ,その他の指標は,主要な資金の方向性と一致するかどうかを決定するために計算される.

主なファンドと補助指標の方向が同じ方向にシグナルを出しているときのみ,戦略はポジションを開く.これは効果的に取引頻度を制御し,高い確率でしか入らない.

ストップ損失出口

ポジションを開いた後,モメンタムトラッキング戦略はリアルタイムで価格変化を追跡し,ATR値の拡大をストップ・ロスの信号として使用します.これは,市場は再びメイン・オペレーション段階に入っており,罠にはまらないようにすぐに現金に脱出する必要があります.

さらに,価格動きが一定の範囲を超えて後退した場合,ストップ・ロスは発生します.これは通常の技術的なリトラセシブであり,リスク管理のために直ちに停止する必要があります.

戦略 の 利点

高度な体系性

モメントトラッキング戦略の最大の利点は,その高度な体系化と標準化である.その取引論理は明確であり,各エントリーと出口には任意の取引の代わりに明確な原則とルールがあります.

この戦略の複製性は非常に強い.ユーザーは手動介入なしで設定後に長期使用のためにそれを適用することができます.

熟練したリスク管理

この戦略には,主要電源判断,補助検証,ストップ損失線設定など,多レベルリスク管理メカニズムが組み込まれていて,非体系的なリスクを効果的に制御できる.

特にこの戦略は,高い確率の状況でのポジションのみを開き,損失を最大限に回避するために科学的ストップ損失点を設定します.これは安定した資本成長を保証します.

比較的持続可能 な 利益

短期戦略と比較して,モメンタムトラッキング戦略の保持期間は長く,各利益は高く,全体的な戦略の収益がより安定して持続可能になります.

さらに,戦略は中長期の動向を追跡し,動向の変動を完全に把握することができます.これは特に主要な動向市場で顕著です.

危険 警告

難しいパラメータ最適化

運動量追跡戦略には,ATRパラメータ,浸透パラメータ,ストップ損失パラメータなど,複数のパラメータが含まれています.これらのパラメータの間には一定の相関性があり,最適なパラメータ組み合わせを見つけるために繰り返しテストが必要です.

パラメータの設定が不適切である場合,取引頻度が過剰またはリスク制御が不十分になる可能性があります.これは,戦略最適化におけるユーザーに一定の経験が必要です.

脱出の罠

戦略が主要パワーとインジケーター信号を決定する時, 価格の突破を信頼して確認します. しかし, 突破作戦で偽の突破が起こり, 罠にかかった可能性が高まります.

重要な突破が失敗すると より大きな損失を伴うかもしれません これは戦略の固有の弱点です

オプティマイゼーションの方向性

機械学習を導入する

機械学習アルゴリズムは,パラメータ間の相関を自動的に検知し,最適なパラメータ組み合わせを見つけるのに使用できます.これは手動テストよりもはるかに効率的です.

具体的には,環境エラーアルゴリズムは,戦略リターンを最大化するために強化学習に基づくパラメータを継続的に繰り返すのに使用できます.

フィルタを増やす

既存の指標 (取引量指標,資本流量指標など) を基に,さらなる補助フィルターを導入し,信頼性を高めるため,突破信号を3回または4回検証することができる.

フィルタの強さはバランスでなければならない. さらにフィルタ自体も相関を避けるべきです.

戦略融合

運動量追跡戦略を他の戦略と組み合わせ,異なる戦略の強みを活用して直角性を達成し,全体的な安定性を向上させる.

例えば 短期的な逆転戦略を導入し 突破後に逆転取引を開くことで より多くの利益を得ることができます

概要

一般的に,モメント・トラッキング・トレーディング・ストラテジーは,推奨される価値のある体系化されたトレンド・トラッキング・ストラテジーである.明確な取引論理,十分なリスク制御を有し,ユーザーに安定かつ効率的な投資収益をもたらすことができる.

この戦略には,いくつかの固有の弱点もあります.この戦略の有効性を最大化するために,パラメータを最適化し,戦略を統合する能力をユーザーに必要としています.全体として,モメントトラッキング戦略は,いくつかの基盤を持つ定量的な愛好家にとって適した定量的な製品です.


/*backtest
start: 2023-12-12 00:00:00
end: 2023-12-15 01:00:00
period: 30m
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

//Created by frasmac2k Strategy credit to Alex Morris

//@version=5
strategy("Mechanical", shorttitle="MECH", overlay=true)

// Get the current date and time
currentYear = year
currentMonth = month
currentDay = dayofmonth

// Create a timestamp for the present date and time
currentTimestamp = timestamp(currentYear, currentMonth, currentDay)

// Define time interval for backtesting
dStart = input(timestamp('2023-07-01'), title='Set Start date', tooltip='Select a start date to run the script from')

// Define direction of strategy
direction = input.string('Forward',title='Direction', tooltip='Forward will go LONG on a Green anchor candle. Inverse will go short on a Green anchor candle and vice versa for Red candle', options=['Forward', 'Inverse'])

// Define the anchor hour as user input with a range of 0 to 23
anchorHour = input.int(11, title="Anchor Hour", tooltip='Set the hour to trade', minval=0, maxval=23)

// Define the take profit and stop loss in pips
takeProfitPips = input.int(10, title='Define TP Pips', tooltip='How many pips do you want to set TP. Choose a sensible value related to the instrument', minval=5)
stopLossPips = input.int(10,'Define SL Pips', tooltip='How many pips do you want to set SL. Choose a sensible value related to the instrument', minval=5)

// Define Tick size
tick10p = input.int(100, title='tick size', tooltip='Choose how many ticks equal 10 pips. This can vary by broker so measure 10 pips on the chart and select how many ticks that equates to. Forex is typically 100. Some instruments such as indices can be 1000', options=[100,1000])

// Declare TP/SL variables
var float takeProfit = na
var float stopLoss = na

// Calculate take profit and stop loss levels in ticks
if tick10p == 100
    takeProfit := takeProfitPips * 10
    stopLoss := stopLossPips * 10
if tick10p == 1000
    takeProfit := takeProfitPips * 100
    stopLoss := stopLossPips * 100

// Declare offset time
var int offset = na

if currentTimestamp > timestamp('2023-10-29')
    offset := 4
else
    offset := 5

//adjust for exchange time
anchorHour := anchorHour - offset

// Define the anchor hour as user input with a range of 0 to 23
tradeHour = anchorHour

// Define logical check for strategy date range
isStratTime = true

// Calculate the time condition for placing the order at the user-defined hour (start of the next hour)
isTradeTime = true

// Logic condition for forwards or inverse
isForward = direction == 'Forward'
isInverse = direction == 'Inverse'

// Declare entry condition variables
var bool longCondition = na
var bool shortCondition = na

// Declare and initialize variables for anchorCandle open and close prices
var float anchorOpen = na
var float anchorClose = na
var float tradeOpen = na
var float tradeClose = na

// Set logic by direction

if isForward
    // Strategy logic
    if isTradeTime and isStratTime
        //Obtain candle open/close
        anchorOpen := open
        anchorClose := close
        // Define entry conditions
        longCondition := anchorClose > anchorOpen
        shortCondition := anchorClose < anchorOpen
        
        // Entry logic
        if longCondition
            strategy.entry("Long", strategy.long)
            strategy.exit("Exit Long", from_entry="Long", profit=takeProfit, loss=stopLoss, comment_profit='TP', comment_loss='SL')
        if shortCondition
            strategy.entry("Short", strategy.short)
            strategy.exit("Exit Short", from_entry="Short", profit=takeProfit, loss=stopLoss, comment_profit='TP', comment_loss='SL')

if isInverse
    // Strategy logic
    if isTradeTime and isStratTime
        //Obtain candle open/close
        anchorOpen := open
        anchorClose := close
        // Define entry conditions
        shortCondition := anchorClose > anchorOpen
        longCondition := anchorClose < anchorOpen
        
        // Entry logic
        if longCondition
            strategy.entry("Long", strategy.long)
            strategy.exit("Exit Long", from_entry="Long", profit=takeProfit, loss=stopLoss, comment_profit='TP', comment_loss='SL')
        if shortCondition
            strategy.entry("Short", strategy.short)
            strategy.exit("Exit Short", from_entry="Short", profit=takeProfit, loss=stopLoss, comment_profit='TP', comment_loss='SL')

// Define the time range for the background shade
startHour = anchorHour
startMinute = 0
endHour = anchorHour
endMinute = 0

// Check if the current time is within the specified range
isInTimeRange = (hour == startHour and minute >= startMinute) or (hour == endHour and minute <= endMinute) or (hour > startHour and hour < endHour)

// Define the background color for the shade
backgroundColor = color.new(color.red, 90)

// Apply the background shade
bgcolor(isInTimeRange ? backgroundColor : na)



もっと