
この戦略は,ポーリング帯,相対的に強い指数 (RSI) とランダムなRSIの3つの技術指標を組み合わせて,価格の変動率と動力を分析し,市場における過剰買いと過剰売り状態を探し,最適な買入と売却のタイミングを決定する.この戦略は,20倍レバレッジの模擬オプション取引を使用し,0.60%のストップポイントと0.25%のストップポイントを設定し,リスクを制御するために1日1回の取引を制限する.
この戦略の核心は,ポリン格帯,RSI,およびランダムなRSIの3つの指標を使用して,市場の状態を評価することです.ポリン格帯は,価格の変動率を測定するために,中軌 ((20周期単調移動平均),上軌 ((中軌上方3標準差) と下軌 ((中軌下方3標準差) を構成しています. RSIは,オーバーバイとオーバーセール条件を識別するために使用される動的振動器です.
RSIが34を下回り,ランダムなRSIが20を下回り,閉盤価格が下位軌道に近いまたは下位軌道以下であるとき,買入シグナルを誘発する. RSIが66以上,ランダムなRSIが80以上,閉盤価格が上位軌道に近いまたは上位軌道上のとき,売り出せシグナルを誘発する.戦略は20倍レバレッジの模擬オプション取引を使用し,ストップポイントは0.60%で,ストップポイントは0.25%で設定されている.
この戦略は,ポーリング帯,RSI,およびランダムなRSIの3つの技術指標を組み合わせて,価格の変動率と動力の情報を活用して,最適な買入と売却のタイミングを探します. この戦略は,明確なストップ・ロスを設定し,毎日取引回数を制御してリスクを管理します. この戦略は,その優位性にもかかわらず,市場リスク,パラメータの感受性,およびレバレッジリスクなどの課題に直面しています.
/*backtest
start: 2024-05-01 00:00:00
end: 2024-05-31 23:59:59
period: 1h
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("Bollinger Bands + RSI + Stochastic RSI Strategy with OTM Options", overlay=true)
// Define leverage factor (e.g., 20x leverage for OTM options)
leverage = 1
// Bollinger Bands
length = 20
deviation = 3
basis = ta.sma(close, length)
dev = ta.stdev(close, length)
upper = basis + deviation * dev
lower = basis - deviation * dev
// RSI
rsi_length = 14
rsi = ta.rsi(close, rsi_length)
// Stochastic RSI
stoch_length = 14
stoch_k = ta.stoch(close, close, close, stoch_length)
// Entry condition with Bollinger Bands
longCondition = rsi < 34 and stoch_k < 20 and close <= lower
shortCondition = rsi > 66 and stoch_k > 80 and close >= upper
// Plot Bollinger Bands
plot(basis, color=color.blue, title="Basis")
plot(upper, color=color.red, title="Upper Bollinger Band")
plot(lower, color=color.green, title="Lower Bollinger Band")
// Track if a trade has been made today
var int lastTradeDay = na
// Options Simulation: Take-Profit and Stop-Loss Conditions
profitPercent = 0.01 // 1% take profit
lossPercent = 0.002 // 0.2% stop loss
// Entry Signals
if (dayofmonth(timenow) != dayofmonth(lastTradeDay))
if (longCondition)
longTakeProfitPrice = close * (1 + profitPercent)
longStopLossPrice = close * (1 - lossPercent)
strategy.entry("Long", strategy.long, qty=leverage * strategy.equity / close)
strategy.exit("Take Profit Long", from_entry="Long", limit=longTakeProfitPrice, stop=longStopLossPrice)
lastTradeDay := dayofmonth(timenow)
if (shortCondition)
shortTakeProfitPrice = close * (1 - profitPercent)
shortStopLossPrice = close * (1 + lossPercent)
strategy.entry("Short", strategy.short, qty=leverage * strategy.equity / close)
strategy.exit("Take Profit Short", from_entry="Short", limit=shortTakeProfitPrice, stop=shortStopLossPrice)
lastTradeDay := dayofmonth(timenow)