PROTECTED SOURCE SCRIPT
Sri - Relative Trend Index (RTI) with CTF

🧭 Sri - Relative Trend Index (RTI) with Custom Timeframe (CTF)
Developed by Venkat Raman (Sri)
📘 Overview
The Relative Trend Index (RTI) is a proprietary oscillator designed to measure trend strength, direction, and relative positioning within a smoothed statistical band.
Unlike standard oscillators, RTI adapts dynamically using custom timeframe data (CTF), allowing traders to evaluate multi-timeframe trend momentum and reversals more effectively.
The indicator uses standard deviation envelopes and quantile-based sensitivity to calculate upper and lower dynamic bands, then measures the relative position of the current price within those bands — resulting in a smoothed, normalized trend index scaled from 0 to 100.
⚙️ Key Features
✅ Custom Timeframe Input (CTF):
Analyze RTI on any timeframe (e.g., 60m, 120m, 1D) while viewing on lower or higher charts.
✅ Color-coded RTI Line:
Green when RTI is above the 50 baseline → bullish trend momentum.
Red when RTI is below the 50 baseline → bearish trend momentum.
✅ Adaptive Smoothing:
Smoothing automatically adjusts based on sensitivity.
Higher sensitivity = smoother RTI curve (reduces noise).
✅ Dynamic Quantile Calculation:
RTI uses quantile-based ranking of upper and lower volatility bands, making it adaptive to market volatility and minimizing lag.
✅ Overbought/Oversold & Mid Levels:
Visual reference zones for identifying potential exhaustion or reversal regions:
Overbought: Default 80
Oversold: Default 20
Midline: 50
✅ Smoothed Signal Line:
Provides an additional reference curve for crossover signals and confirmation.
✅ Visual Clarity:
Clean color-coded plots
Overbought/Oversold fill shading
Adaptive smoothing curve overlay
✅ Alert Conditions Included:
Ready-to-use alerts for:
Crossing overbought/oversold levels
Crossing midline (50)
Signal crossovers between RTI and smoothed line
🧩 Inputs Explained
Input Description
Custom Timeframe (CTF) Selects timeframe used for RTI calculation (e.g., 60, 120, D).
Trend Length Period used to calculate trend envelope range.
Sensitivity Adjusts responsiveness (lower = faster, higher = smoother).
Base Smoothing Length Controls EMA smoothing of the signal line.
Overbought / Oversold Thresholds for reversal or momentum exhaustion zones.
🟩 Interpretation
RTI > 50 (Green): Uptrend or bullish bias; stronger if rising toward 80+.
RTI < 50 (Red): Downtrend or bearish bias; stronger if falling toward 20 or below.
Crossing 50: Often indicates a shift in momentum.
Signal crossover (RTI vs. EMA): Potential early entry/exit trigger.
🔔 Built-In Alerts
RTI crossing Overbought / Oversold
RTI crossing 50 baseline
RTI crossing Smoothed Signal Line
🧠 Suggested Uses
Combine with volume, price structure, or volatility-based tools for confirmation.
Use higher-timeframe RTI (via CTF) as a trend filter and lower-timeframe RTI for entry timing.
Ideal for swing traders and intraday analysts seeking adaptive trend strength confirmation.
🎨 Color Scheme
Element Color Meaning
RTI Line 🟢 Green / 🔴 Red Above or below 50 baseline
Smoothed RTI 🔵 Blue (light) Reference EMA of RTI
Background Fill 🩵 Soft Teal Highlights oscillator zone
💡 Note
This is a proprietary adaptation of the Relative Trend Index concept by Sri (Venkat Raman), optimized for flexibility, visual clarity, and dynamic responsiveness across multiple timeframes.
Developed by Venkat Raman (Sri)
📘 Overview
The Relative Trend Index (RTI) is a proprietary oscillator designed to measure trend strength, direction, and relative positioning within a smoothed statistical band.
Unlike standard oscillators, RTI adapts dynamically using custom timeframe data (CTF), allowing traders to evaluate multi-timeframe trend momentum and reversals more effectively.
The indicator uses standard deviation envelopes and quantile-based sensitivity to calculate upper and lower dynamic bands, then measures the relative position of the current price within those bands — resulting in a smoothed, normalized trend index scaled from 0 to 100.
⚙️ Key Features
✅ Custom Timeframe Input (CTF):
Analyze RTI on any timeframe (e.g., 60m, 120m, 1D) while viewing on lower or higher charts.
✅ Color-coded RTI Line:
Green when RTI is above the 50 baseline → bullish trend momentum.
Red when RTI is below the 50 baseline → bearish trend momentum.
✅ Adaptive Smoothing:
Smoothing automatically adjusts based on sensitivity.
Higher sensitivity = smoother RTI curve (reduces noise).
✅ Dynamic Quantile Calculation:
RTI uses quantile-based ranking of upper and lower volatility bands, making it adaptive to market volatility and minimizing lag.
✅ Overbought/Oversold & Mid Levels:
Visual reference zones for identifying potential exhaustion or reversal regions:
Overbought: Default 80
Oversold: Default 20
Midline: 50
✅ Smoothed Signal Line:
Provides an additional reference curve for crossover signals and confirmation.
✅ Visual Clarity:
Clean color-coded plots
Overbought/Oversold fill shading
Adaptive smoothing curve overlay
✅ Alert Conditions Included:
Ready-to-use alerts for:
Crossing overbought/oversold levels
Crossing midline (50)
Signal crossovers between RTI and smoothed line
🧩 Inputs Explained
Input Description
Custom Timeframe (CTF) Selects timeframe used for RTI calculation (e.g., 60, 120, D).
Trend Length Period used to calculate trend envelope range.
Sensitivity Adjusts responsiveness (lower = faster, higher = smoother).
Base Smoothing Length Controls EMA smoothing of the signal line.
Overbought / Oversold Thresholds for reversal or momentum exhaustion zones.
🟩 Interpretation
RTI > 50 (Green): Uptrend or bullish bias; stronger if rising toward 80+.
RTI < 50 (Red): Downtrend or bearish bias; stronger if falling toward 20 or below.
Crossing 50: Often indicates a shift in momentum.
Signal crossover (RTI vs. EMA): Potential early entry/exit trigger.
🔔 Built-In Alerts
RTI crossing Overbought / Oversold
RTI crossing 50 baseline
RTI crossing Smoothed Signal Line
🧠 Suggested Uses
Combine with volume, price structure, or volatility-based tools for confirmation.
Use higher-timeframe RTI (via CTF) as a trend filter and lower-timeframe RTI for entry timing.
Ideal for swing traders and intraday analysts seeking adaptive trend strength confirmation.
🎨 Color Scheme
Element Color Meaning
RTI Line 🟢 Green / 🔴 Red Above or below 50 baseline
Smoothed RTI 🔵 Blue (light) Reference EMA of RTI
Background Fill 🩵 Soft Teal Highlights oscillator zone
💡 Note
This is a proprietary adaptation of the Relative Trend Index concept by Sri (Venkat Raman), optimized for flexibility, visual clarity, and dynamic responsiveness across multiple timeframes.
สคริปต์ที่ได้รับการป้องกัน
สคริปต์นี้ถูกเผยแพร่เป็นแบบ closed-source อย่างไรก็ตาม คุณสามารถใช้ได้อย่างอิสระและไม่มีข้อจำกัดใดๆ – เรียนรู้เพิ่มเติมได้ที่นี่
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน
สคริปต์ที่ได้รับการป้องกัน
สคริปต์นี้ถูกเผยแพร่เป็นแบบ closed-source อย่างไรก็ตาม คุณสามารถใช้ได้อย่างอิสระและไม่มีข้อจำกัดใดๆ – เรียนรู้เพิ่มเติมได้ที่นี่
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน