OPEN-SOURCE SCRIPT

RSI ⇄ SMA Cross Alerts (80/20, On Close)

55
RSI ⇄ SMA Cross Alerts (80/20, On Close)
Add //version=5 (required in Pine v5).

Your logic is fine for “after being >80/<20 then RSI crosses its SMA,” and barstate.isconfirmed enforces on close.

plot(close) in a non-overlay RSI pane will squash the scale—drop it (or set overlay=true and move RSI to a separate scale, but simplest is just remove it).

Optional: expose source, add a tiny cooldown, and let alerts include close/RSI values.

คำจำกัดสิทธิ์ความรับผิดชอบ

ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน