Trending True Range

Display a smoothed true range during trending markets, thus filtering any measurement occurring during ranging markets. Whether the market is trending or ranging is determined by the position of the efficiency ratio relative to its Wilder moving average.


  • Resolution : resolution of the indicator
  • Length : period of the efficiency ratio and the Wilder moving averages used in the script


If you are not interested in volatility during ranging markets, this indicator might result useful to you. An interesting aspect is that it both measures volatility , but also determine whether the market is trending or ranging, with a zero value indicating a ranging market.

Indicator against Atr, with both length = 14, our indicator might be easier to interpret.


Thx to my twitter followers for their suggestions regarding this indicator. I apologize if it's a bit short, the original code was longer and included more options, but forcing a script to be lengthy is a really bad idea, so I stayed with something less flashy but certainly more practical, "classic Grover" some might say.

Thx for reading!

إزالة من البرامج النصية المفضلة أضف إلى البرامج النصية المفضلة

Become a Patreon and get access to exclusive technical indicators!

You can also check out some of the indicators I made for luxalgo :


Mate, this is some great stuff. I've been using multiple instances of this at different lengths (short-long) to help identify market context and as a trade filter and it's working great as part of my confluence/price action strategy. Much appreciate your open source work. Cheers
+1 رد
@TJ_667, Yr welcome :)
Your ability to innovate was amazing, I envy.
+1 رد
AlexCar LunaOwl
@LunaOwl, Lol two of my favorite authors on the same thread. : D
Already put it to use thanks Alex! P.S. what adaptive MA would you recommend?
+1 رد
Thank you so much, @alexgrover.
+1 رد
Great work, thank you! You truly are efficient at making code short.
+1 رد
xfob xfob
@alexgrover I forgot to ask, how come you chose RMA? Is there an advantage over other smoothers in this specific case? Thanks!
+1 رد
@xfob, The average true range is simply the RMA of the true range, as such I wanted to use the RMA, compared to an EMA the RMA is smoother.
xfob alexgrover
@alexgrover, oh right! I've been learning a lot from the teachings in your posts, thank you again for all of it.

What springs to mind when I asked the question about the smoother is the lag involved in RMA. Is the only way to get "zero lag" by increasing the amplitude response and zeroing the phase response? This has the undesired effects for this specific indicator because it causes overshoot (unwanted bumps) where it should be zero. In your expert opinion, is it possible reduce lag without the expense of non-causality? I'm bad at math so it's tough to wrap my head around this stuff.
+1 رد
الصفحة الرئيسية منصة الأسهم منصًة العملات منصّة العملات الرقمية جدول الأعمال الاقتصادي كيف تعمل مميزات الرسم البياني أسعار العضوية إحالة صديق قوانين الموقع مركز المساعدة حلول المواقع الإلكترونية والوسطاء الأدوات حلول الرسوم البيانية مكتبة الرسوم البيانية صغيرة الحجم المدوّنة والأخبار تويتر
ملف التعريف إعدادات الصفحة الشخصية الحساب وإعداد الفواتير الأصدقاء المُحالون العملات الافتراضية تذاكر الدعم الخاصة بي مركز المساعدة التحاليل المنشورة المتابعين تُتابع رسالة خاصة المحادثة تسجيل الخروج