RSI と RSI の 均等化 の 上昇 差異 戦略

作者: リン・ハーンチャオチャン,日付: 2024-03-01 12:11:58
タグ:

img

概要

この戦略は,RSIインジケーターとスムーズなRSIインジケーターを組み合わせて,価格底辺で購入機会を見つけます.RSIが新しい低点に達し,価格が新しい低点に達しない場合,それは上昇した分散信号とみなされます.スムーズなRSIトレンド判断を追加することで,戦略のパフォーマンスを改善することができます.

戦略の論理

  1. RSIインジケーターを 14 期で計算する.
  2. 均等化効果を得るため,WMAを2倍にして均等化RSIを計算する.
  3. RSIが30を下回っているか確認します
  4. RSIが35を下回っているか確認します
  5. RSIの最低点が25以下かどうか確認します
  6. RSIが新低に達し 価格が上昇しないように計算します
  7. RSIが平らければ 3期以上続く.
  8. 上記の条件がすべて満たされたときに購入信号を起動します.
  9. ストップ・ロストと 収益条件を設定します

この戦略は主にRSI逆転特性に依存し,RSIトレンド判断をスムーズに組み合わせ,RSIが過売されている間に価格が圧迫されているときに購入する.ストップ損失または利益を得るときにポジションを閉じる.

利点分析

  1. 二重RSI指標の組み合わせは 戦略のパフォーマンスを向上させます
  2. RSIの逆転機能を利用します 確率の利点はあります
  3. RSIのトレンド判断は 誤った逆転を避けるのに役立ちます
  4. 完全にストップ・ロストと 利得を収める論理が リスクを制限できます

リスク分析

  1. RSIの逆転の失敗の可能性は完全に避けられません
  2. RSIが滑らかした場合は 遅延効果があり 最適のエントリータイミングを 逃す可能性があります
  3. ストップ・ロスは太りすぎると 損失が増える危険性があります

RSIパラメータを調整することでエントリータイミングを最適化できます. ストップロスの距離を絞り,より速くストップアウトできます. トレンドリスクを判断するために他の指標と組み合わせ,誤った逆転率を下げます.

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

  1. 異なるパラメータセットで RSI の試験効果
  2. より良いスムージング品質のために,スムージングRSI計算を改善します.
  3. ストップ・ロスを調整し 利得ポイントを取って 最適のリスク・報酬比を見つけます
  4. 低勢力の状況を避けるため,モメントインジケーターなどを追加します.

パラメータ調整とより多くの指標の組み合わせによって戦略のパフォーマンスをさらに改善します

結論

この戦略は,全体的にRSI逆転特性を利用している.ダブルRSIの組み合わせは,逆転効果を完全に活用しながら,指標のダイバージェンスから不確実性を導入する.これは典型的な指標戦略のアイデアである. 絶え間ないテストと最適化を通じて指標の適応性を向上させることができる. また,誤判を減らすためにより多くの指標を組み合わせ,強度を高める.


/*backtest
start: 2024-01-30 00:00:00
end: 2024-02-29 00:00:00
period: 1m
basePeriod: 1m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © BigBitsIO

//@version=4
strategy(title="RSI and Smoothed RSI Bull Div Strategy [BigBitsIO]", shorttitle="RSI and Smoothed RSI Bull Div Strategy [BigBitsIO]", overlay=true, pyramiding=1, default_qty_type=strategy.percent_of_equity, default_qty_value=100, commission_type=strategy.commission.percent, commission_value=.1, slippage=0)


TakeProfitPercent = input(3, title="Take Profit %", type=input.float, step=.25)
StopLossPercent = input(1.75, title="Stop Loss %", type=input.float, step=.25)

RSICurve = input(14, title="RSI Lookback Period", type=input.integer, step=1)
BuyBelowTargetPercent = input(0, title="Buy Below Lowest Low In RSI Divergence Lookback Target %", type=input.float, step=.05)
BuyBelowTargetSource = input(close, title="Source of Buy Below Target Price", type=input.source)
SRSICurve = input(10, title="Smoothed RSI Lookback Period", type=input.integer, step=1)
RSICurrentlyBelow = input(30, title="RSI Currently Below", type=input.integer, step=1)
RSIDivergenceLookback = input(25, title="RSI Divergence Lookback Period", type=input.integer, step=1)
RSILowestInDivergenceLookbackCurrentlyBelow  = input(25, title="RSI Lowest In Divergence Lookback Currently Below", type=input.integer, step=1)
RSISellAbove = input(65, title="RSI Sell Above", type=input.integer, step=1)
MinimumSRSIDownTrend = input(3, title="Minimum SRSI Downtrend Length", type=input.integer, step=1)
SRSICurrentlyBelow = input(35, title="Smoothed RSI Currently Below", type=input.integer, step=1)

PlotTarget = input(false, title="Plot Target")


RSI = rsi(close, RSICurve)
SRSI = wma(2*wma(RSI, SRSICurve/2)-wma(RSI, SRSICurve), round(sqrt(SRSICurve))) // Hull moving average

SRSITrendDownLength = 0
if (SRSI < SRSI[1])
    SRSITrendDownLength := SRSITrendDownLength[1] + 1

// Strategy Specific
ProfitTarget = (close * (TakeProfitPercent / 100)) / syminfo.mintick
LossTarget = (close * (StopLossPercent / 100)) / syminfo.mintick
BuyBelowTarget = BuyBelowTargetSource[(lowestbars(RSI, RSIDivergenceLookback)*-1)] - (BuyBelowTargetSource[(lowestbars(RSI, RSIDivergenceLookback)*-1)] * (BuyBelowTargetPercent / 100))

plot(PlotTarget ? BuyBelowTarget : na)



bool IsABuy = RSI < RSICurrentlyBelow and SRSI < SRSICurrentlyBelow and lowest(SRSI, RSIDivergenceLookback) < RSILowestInDivergenceLookbackCurrentlyBelow and BuyBelowTargetSource < BuyBelowTarget and SRSITrendDownLength >= MinimumSRSIDownTrend and RSI > lowest(RSI, RSIDivergenceLookback)
bool IsASell = RSI > RSISellAbove

if IsABuy
    strategy.entry("Positive Trend", true) // buy by market
    strategy.exit("Take Profit or Stop Loss", "Positive Trend", profit = ProfitTarget, loss = LossTarget)
if IsASell
    strategy.close("Positive Trend")


もっと