| //@version=6 | |
| indicator(title="RSI + MA (RSI System)", shorttitle="RSI+MA", overlay=false) | |
| // ─── Inputs (phải khớp với strategy rsi.pine) ───────────────────────────────── | |
| rsiLen = input.int(14, title="RSI Length", minval=1, group="RSI Settings") | |
| buyThreshold = input.float(55, title="RSI Buy Threshold (≥)", step=0.5, group="RSI Settings") | |
| sellThreshold = input.float(45, title="RSI Sell Threshold (≤)", step=0.5, group="RSI Settings") | |
| maSlowLen = input.int(200, title="MA Slow Length", minval=2, group="MA Settings") | |
| maFastLen = input.int(20, title="MA Fast Length", minval=1, group="MA Settings") | |
| // ─── Tính toán ──────────────────────────────────────────────────────────────── | |
| rsi_indi = ta.rsi(close, rsiLen) | |
| maSlow = ta.sma(rsi_indi, maSlowLen) | |
| maFast = ta.sma(rsi_indi, maFastLen) | |
| // ─── Plots ──────────────────────────────────────────────────────────────────── | |
| plot(rsi_indi, title="RSI", color=color.aqua, linewidth=2) | |
| plot(maSlow, title="MA Slow", color=color.red, linewidth=1) | |
| plot(maFast, title="MA Fast", color=color.yellow, linewidth=1) | |
| hline(buyThreshold, "Buy Threshold", color=color.new(color.lime, 40), linestyle=hline.style_dashed) | |
| hline(sellThreshold, "Sell Threshold", color=color.new(color.red, 40), linestyle=hline.style_dashed) | |
Xet Storage Details
- Size:
- 1.67 kB
- Xet hash:
- eacc376a3079b77624ff6c0ddf551a4d6e1c1e471b09e49ed6de33f1c1c4b32a
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.