この戦略は,5日間の移動平均帯とGBS購入/販売信号を組み合わせて,トレンド方向を特定し,取引信号を生成する.移動平均帯はトレンド方向と主要なサポート/レジスタンスレベルを判断するために使用され,GBS購入/販売信号はトレンド方向の下の正確なエントリータイミングを見つけるために使用される.この戦略は中期トレンド取引に適しており,レンジ限定市場で過剰な収益を達成することができます.
この戦略は,移動平均帯とGBS購入/販売信号を統合し,市場のノイズをフィルターするために明確なトレンド方向を特定した後,高い信頼性で動作します.中期利益をロックし,タイミングで退出することができます. 戦略は資本利用においてシンプルで効率的で,量子トレーダーに安定した利益を提供します. 継続的な最適化と繰り返しは,勝利率と収益性をさらに改善することができます.
/*backtest start: 2024-01-05 00:00:00 end: 2024-02-04 00:00:00 period: 4h basePeriod: 15m exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}] */ //@version=5 strategy("5MABAND + GBS Buy & Sell Strategy", overlay=true) // Command 1 - 5MABAND Calculation length = input(5, title="Number of Candles for Average") avgHigh = ta.sma(high, length) avgLow = ta.sma(low, length) // Plotting 5MABAND Bands plot(avgHigh, color=color.green, title="5MABAND High Line", linewidth=1) plot(avgLow, color=color.red, title="5MABAND Low Line", linewidth=1) // Command 2 - GBS concept Buy Entry gbsBuyCondition = close > open and high - close < close - open and open - low < close - open and close - open > close[1] - open[1] and close - open > close[2] - open[2] and close - open > close[3] - open[3] and close[1] < avgHigh and close[2] < avgHigh and close[3] < avgHigh and open[1] < avgHigh and open[2] < avgHigh and open[3] < avgHigh // Command 3 - GBS Concept Sell Entry gbsSellCondition = open - close > open[1] - close[1] and open - close > open[2] - close[2] and open - close > open[3] - close[3] and open[1] > avgLow and open[2] > avgLow and open[3] > avgLow and open - close > open - low and open - close > high - open // Command 6 - 5MABAND Exit Trigger exitTriggerCandle_5MABAND_Buy = low < avgLow exitTriggerCandle_5MABAND_Sell = high > avgHigh // Exit Signals for 5MABAND exitBuySignal_5MABAND = close < avgLow exitSellSignal_5MABAND = close > avgHigh // Execute Buy and Sell Orders strategy.entry("Buy", strategy.long, when = gbsBuyCondition) strategy.close("Buy", when = exitBuySignal_5MABAND) strategy.entry("Sell", strategy.short, when = gbsSellCondition) strategy.close("Sell", when = exitSellSignal_5MABAND) // Exit Buy and Sell Orders for 5MABAND strategy.close("Buy", when = exitTriggerCandle_5MABAND_Buy) strategy.close("Sell", when = exitTriggerCandle_5MABAND_Sell)