OPEN-SOURCE SCRIPT
ATR % Oscillator - DolphinTradeBot

1️⃣Overview
🔸 This is a simplified version of ATR and TR that shows volatility as percentage changes, making it easier to compare two symbols.
🔸 The indicator compares the volatility of two different assets by calculating the percentage-based price ranges and their moving averages.
📌 This is especially useful for pair traders, as it helps identify which symbol is more volatile, allowing for strategic decisions based on relative movement rather than overall market direction.
2️⃣How Is It Work?
🔸 For each symbol, it calculates the absolute percentage difference between either:
• Close and Open (net price change), or
• High and Low (daily price range).
🔸 The results are visualized as column bars — the taller the bar, the higher the volatility.
🔸 It also plots a moving average line (SMA) based on the selected range length.
📌 These calculations are independent of the chart you're on — they work purely based on the two selected symbols.
If no symbols are selected, it defaults to using the current chart's symbol.
3️⃣How to Use It?
With this indicator, you can:
🔸 Compare the volatility between two assets.
🔸 Detect sudden volatility spikes that may signal upcoming momentum.
🔸 Support spread, arbitrage, or correlation-based strategies.
🔸 See which symbol is gaining market attention (a larger difference = more activity).
Example: Compare BTC vs ETH to see which one is dominating in terms of price action or volatility.
4️⃣⚙️Settings
🔸 Symbol Settings
• Symbol-1 / Symbol-2: Choose the two assets to compare.
• Checkboxes: Enable/disable visibility for each symbol's data.
🔸 Calculation Settings
• Range Average: The number of bars used for the moving average.
• Calculation Source:
- Close-Open: Measures net price movement.
- High-Low: Measures total price range.
🔸 This is a simplified version of ATR and TR that shows volatility as percentage changes, making it easier to compare two symbols.
🔸 The indicator compares the volatility of two different assets by calculating the percentage-based price ranges and their moving averages.
📌 This is especially useful for pair traders, as it helps identify which symbol is more volatile, allowing for strategic decisions based on relative movement rather than overall market direction.
2️⃣How Is It Work?
🔸 For each symbol, it calculates the absolute percentage difference between either:
• Close and Open (net price change), or
• High and Low (daily price range).
🔸 The results are visualized as column bars — the taller the bar, the higher the volatility.
🔸 It also plots a moving average line (SMA) based on the selected range length.
📌 These calculations are independent of the chart you're on — they work purely based on the two selected symbols.
If no symbols are selected, it defaults to using the current chart's symbol.
3️⃣How to Use It?
With this indicator, you can:
🔸 Compare the volatility between two assets.
🔸 Detect sudden volatility spikes that may signal upcoming momentum.
🔸 Support spread, arbitrage, or correlation-based strategies.
🔸 See which symbol is gaining market attention (a larger difference = more activity).
Example: Compare BTC vs ETH to see which one is dominating in terms of price action or volatility.
4️⃣⚙️Settings
🔸 Symbol Settings
• Symbol-1 / Symbol-2: Choose the two assets to compare.
• Checkboxes: Enable/disable visibility for each symbol's data.
🔸 Calculation Settings
• Range Average: The number of bars used for the moving average.
• Calculation Source:
- Close-Open: Measures net price movement.
- High-Low: Measures total price range.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
للوصول السريع إلى الرسم البياني، أضف هذا النص البرمجي إلى مفضلاتك - تعرف على المزيد هنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
للوصول السريع إلى الرسم البياني، أضف هذا النص البرمجي إلى مفضلاتك - تعرف على المزيد هنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.