OPEN-SOURCE SCRIPT
Long-short energy ratio /多空能量比值

This indicator calculates the relative strength of bulls and bears by measuring the average candle body movement within a user-defined window (default: 50 bars).
Bull Energy = average percentage change of all bullish candles in the lookback period
Bear Energy = average percentage change of all bearish candles in the lookback period
Energy Ratio = Bull Energy ÷ Bear Energy
The ratio is plotted as a curve around the baseline of 1:
Ratio > 1 → Bull side shows stronger momentum
Ratio < 1 → Bear side shows stronger momentum
Ratio ≈ 1 → Balanced market conditions
This tool helps visualize short-term shifts in buying and selling pressure, offering a simple mean-reversion perspective or a confirmation of trend strength depending on the context.
Bull Energy = average percentage change of all bullish candles in the lookback period
Bear Energy = average percentage change of all bearish candles in the lookback period
Energy Ratio = Bull Energy ÷ Bear Energy
The ratio is plotted as a curve around the baseline of 1:
Ratio > 1 → Bull side shows stronger momentum
Ratio < 1 → Bear side shows stronger momentum
Ratio ≈ 1 → Balanced market conditions
This tool helps visualize short-term shifts in buying and selling pressure, offering a simple mean-reversion perspective or a confirmation of trend strength depending on the context.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.