
Dual RSI Average Breakout Strategi adalah strategi kuantitatif yang menggunakan RSI dan Average Breakout Strategi untuk menilai waktu perdagangan. Gagasan inti dari strategi ini adalah bahwa ketika RSI mencapai area overbought oversold, menggunakan arah rata-rata untuk memfilter sinyal, mencari titik-titik yang lebih baik untuk membuat posisi.
Indeks RSI dan SMA bergerak sederhana dihitung berdasarkan parameter yang ditetapkan oleh pengguna.
Ketika RSI melewati batas oversold yang ditetapkan (default 30), sinyal multihead akan dihasilkan jika harga berada di bawah garis rata-rata LONG exit.
Ketika RSI melewati garis overbought yang ditetapkan di bawah (default 70), sinyal overhead dihasilkan jika harga berada di atas garis rata-rata keluar SHORT.
Pengguna dapat memilih garis rata-rata penyaringan, dan sinyal akan muncul ketika harga berada di atas garis rata-rata penyaringan.
Keluar dari posisi dilakukan berdasarkan garis keluar rata-rata LONG dan garis keluar rata-rata SHORT.
Desain indikator ganda, yang secara komprehensif mengacu pada dua faktor pasar, meningkatkan akurasi keputusan.
Menggunakan karakteristik reversal dari RSI untuk mencari waktu reversal.
Filter rata-rata meningkatkan kewaspadaan dalam penilaian dan menghindari kebocoran.
Hal ini memungkinkan parameter kustom yang dapat dioptimalkan untuk varietas dan siklus yang berbeda.
Desain logis yang sederhana, mudah dipahami dan dimodifikasi.
Indikator RSI mudah menghasilkan garis vertikal, dan indikator density dapat mengurangi masalah ini.
RSI pada periode besar mudah gagal, dapat mengurangi parameter optimasi atau membantu indikator lain.
Garis rata-rata memiliki keterbelakangan, yang dapat dipersingkat sesuai dengan panjang garis rata-rata atau membantu indikator seperti MACD.
Pengertian yang lebih sederhana, dapat memperkenalkan lebih banyak indikator untuk memastikan sinyal perdagangan bekerja.
Mengoptimalkan parameter RSI atau memperkenalkan indikator Density mengurangi probabilitas sinyal palsu.
Kombinasi tren dan indikator fluktuasi seperti DMI, BOLL untuk menentukan tren dan level dukungan.
Memperkenalkan indikator alternatif atau koordinasi penilaian kesetaraan seperti MACD.
Menambahkan logika kondisi posisi terbuka untuk mencegah sinyal penembusan yang tidak diinginkan.
Strategi penembusan rata-rata RSI ganda menggunakan metode RSI untuk menilai overbought dan oversold dan menilai tren rata-rata, secara teoritis dapat secara efektif menangkap peluang pembalikan. Strategi ini fleksibel, sederhana, mudah dikelola, dan juga cocok untuk pengoptimalan berbagai varietas, merupakan strategi awal yang disarankan. Dengan memperkenalkan lebih banyak indikator untuk membantu penilaian, strategi ini dapat lebih meningkatkan efektivitas keputusan dan meningkatkan peluang keuntungan.
/*backtest
start: 2024-01-16 00:00:00
end: 2024-01-23 00:00:00
period: 5m
basePeriod: 1m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//Global Market Signals: RSI Strategy.
//@version=4
strategy("GMS: RSI Strategy", overlay=true)
LongShort = input(title="Long Only or Short Only or Both?", type=input.string, defval="Both", options=["Both", "Long Only", "Short Only"])
RSILength = input(title="RSI Length", type = input.integer ,defval=14)
RSIUpper = input(title="Upper Threshold", type = input.float ,defval=70)
RSILower = input(title="Lower Threshold", type = input.float ,defval=30)
LongExit = input(title="Long Exit SMA Length", type = input.integer ,defval=5)
ShortExit = input(title="Short Exit SMA Length", type = input.integer ,defval=5)
AboveBelow = input(title="Trend SMA Filter?", type=input.string, defval="Above", options=["Above", "Below", "Don't Include"])
TrendLength = input(title="Trend SMA Length", type = input.integer ,defval=200)
//Long Side
if LongShort =="Long Only" and AboveBelow == "Above"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit) and close>sma(close,TrendLength))
strategy.close("LONG", when = close>sma(close,LongExit))
if LongShort =="Long Only" and AboveBelow == "Below"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit) and close<sma(close,TrendLength))
strategy.close("LONG", when = close>sma(close,LongExit))
if LongShort =="Long Only" and AboveBelow == "Don't Include"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit))
strategy.close("LONG", when = close>sma(close,LongExit))
if LongShort =="Both" and AboveBelow == "Above"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit) and close>sma(close,TrendLength))
strategy.close("LONG", when = close>sma(close,LongExit))
if LongShort =="Both" and AboveBelow == "Below"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit) and close<sma(close,TrendLength))
strategy.close("LONG", when = close>sma(close,LongExit))
if LongShort =="Both" and AboveBelow == "Don't Include"
strategy.entry("LONG", true, when = rsi(close,RSILength)<RSILower and close< sma(close,LongExit))
strategy.close("LONG", when = close>sma(close,LongExit))
//SHORT SIDE
if LongShort =="Short Only" and AboveBelow == "Above"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit) and close>sma(close,TrendLength))
strategy.close("SHORT", when = close<sma(close,ShortExit))
if LongShort =="Short Only" and AboveBelow == "Below"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit) and close<sma(close,TrendLength))
strategy.close("SHORT", when = close<sma(close,ShortExit))
if LongShort =="Short Only" and AboveBelow == "Don't Include"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit))
strategy.close("SHORT", when = close<sma(close,ShortExit))
if LongShort =="Both" and AboveBelow == "Above"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit) and close>sma(close,TrendLength))
strategy.close("SHORT", when = close<sma(close,ShortExit))
if LongShort =="Both" and AboveBelow == "Below"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit) and close<sma(close,TrendLength))
strategy.close("SHORT", when = close<sma(close,ShortExit))
if LongShort =="Both" and AboveBelow == "Don't Include"
strategy.entry("SHORT", false, when = rsi(close,RSILength)>RSIUpper and close> sma(close,ShortExit))
strategy.close("SHORT", when = close<sma(close,ShortExit))