Chartaraชาร์ตารา
Trend + momentum · Pine Script v6

Trend Compass

Combines two EMAs with RSI context to label constructive, defensive and neutral regimes.

تنزيل مجاني
ما الذي يعرضه

ما الذي يعرضه

  • Fast and slow trend structure
  • Momentum context around RSI 50
  • A calm three-state chart background
Limits

ما الذي لا يفعله

  • Predict reversals
  • Set entries or exits
  • Replace risk management
3 minutes

طريقة التثبيت

  1. Open TradingView and select Pine Editor.
  2. Paste the code below into a new indicator.
  3. Save, add to chart and adjust inputs for your own test.
Trend Compass.pine
//@version=6
indicator("Chartara — Trend Compass", overlay = true)

// Educational indicator. It describes market structure; it is not a buy/sell system.
int fastLength = input.int(21, "Fast EMA", minval = 2)
int slowLength = input.int(55, "Slow EMA", minval = 3)
int rsiLength = input.int(14, "RSI length", minval = 2)
bool showBackground = input.bool(true, "Show regime background")

float fastEma = ta.ema(close, fastLength)
float slowEma = ta.ema(close, slowLength)
float rsiValue = ta.rsi(close, rsiLength)

bool bullish = fastEma > slowEma and rsiValue > 50
bool bearish = fastEma < slowEma and rsiValue < 50
color regimeColor = bullish ? color.new(#43D9B3, 86) : bearish ? color.new(#FF6B7A, 88) : color.new(#F4C95D, 91)

plot(fastEma, "Fast EMA", color = #43D9B3, linewidth = 2)
plot(slowEma, "Slow EMA", color = #7CA8FF, linewidth = 2)
bgcolor(showBackground ? regimeColor : na, title = "Regime")

alertcondition(bullish and not bullish[1], "Trend Compass turned constructive", "Trend Compass is constructive. Review price structure and risk before acting.")
alertcondition(bearish and not bearish[1], "Trend Compass turned defensive", "Trend Compass is defensive. Review price structure and risk before acting.")

Broker Compass

استخدمه مع الإعداد المناسب

كل دليل يقود إلى مقارنة ذات صلة وليس إلى تسجيل إجباري.

مقارنة الوسطاء