alexgrover

Grover Llorens Activator [alexgrover & Lucía Llorens]

Trailing stops play a key role in technical analysis and are extremely popular trend following indicators. Their main strength lie in their ability to minimize whipsaws while conserving a decent reactivity, the most popular ones include the Supertrend, Parabolic SAR and Gann Hilo activator . However, and like many indicators, most trailing stops assume an infinitely long trend, which penalize their ability to provide early exit points, this isn't the case of the parabolic SAR who take this into account and thus converge toward the price at an increasing speed the longer a trend last.

Today a similar indicator is proposed. From an original idea of alexgrover & Lucía Llorens who wanted to revisit the classic parabolic SAR indicator, the Llorens activator aim to converge toward the price the longer a trend persist, thus allowing for potential early and accurate exit points. The code make use of the idea behind the price curve channel that you can find here :


I tried to make the code as concise as possible.

The Indicator

The indicator posses 2 user settings, length and mult, length control the rate of convergence of the indicator, with higher values of length making the indicator output converge more slowly toward the price. Mult is also related with the rate of convergence, basically once the price cross the trailing stop its value will become equal to the previous trailing stop value plus/minus mult*atr depending on the previous trailing stop value, therefore higher values of mult will require more time for the trailing stop to reach the closing price, use higher values of mult if you want to avoid potential whipsaws.


Above the indicator with slow convergence time (high length) and low mult .


Points with early exit points are highlighted.

Usage For Oscillators

The difference between the closing price and an overlay indicator can provide an oscillator with characteristics depending on the indicators used for differencing, Lucía Llorens stated that we should find indicators for differencing that highlight the cycles in the price, in other terms : Price - Signal, where we want to find Signal such that we maximize the visibility of the cycles, it can be demonstrated that in the case where the closing price is an additive model : Trend + Cycles + Noise, the zero lag estimation of the Trend component can allow for the conservation of the cycle and noise component, that is : Price - Estimate(Trend), for example the difference between the price and moving average isn't optimal because of the moving average lag, instead the use of zero lag moving averages is more suitable, however the proposed indicator allow for a surprisingly good representation of the cycles when using differencing.


The normalization of this oscillator (via the RSI ) allow to make the peak amplitude of the cycles more constant. Note however that such method can return an output with a sign inverse to the one of the original cycle component.

Conclusion

We proposed an indicator which share the logic of the SAR indicator, that is using convergence toward the price in order to provide early exit points detection. We have seen that this indicator can be used to highlight cycles when used for differencing and i don't exclude publishing more indicators based on this method.

Lucía Llorens has been a great person to work with, and provided enormous feedback and support while i was coding the indicator, this is why i include her in the indicator name as well as copyright notice. I hope we can make more indicators togethers in the future.

(altho i was against using buy/sells labels xD !)

Thanks for reading !




הערות שחרור: - Removed barssince/crossover/under/valuewhen functions from ts in order to avoid unexpected behaviors.
- Changed plot style for cleaner plot.

Thx @LucF
הערות שחרור: fixed repainting issues without heavy alterations of the indicator
הסר מסקריפטים מועדפים הוסף לסקריפטים מועדפים
« Je suis las des cruautés de mes semblables, qui ne sont pas mes pareils.

« Je prendrai l’essor et je m’envolerai vers la mer.

« Je connaîtrai le goût des brises du large. J’entendrai les grands cris de la tempête.

תגובות

I have been checking this indicator and I must say it is pretty amazing.

With good money management, realistic TP and tight SL this can do wonders in account compounding.

Keep up the good work, you are an amazing contributor to this platform
השב
Thank you Alex. Awesome.
השב
Repainting issues have been fixed, note however that the original indicator isn't supposed to be recalculated every time it is loaded, only the last value of each variables in the indicator need to be stored in order for the indicator to work has intended. We can say that the indicator has been adapted to the way Tradingview deal with indicator recalculations.
השב
@alexgrover I got some great results with this indicator and read your comment below that it "should" not repaint. However, I saved a few numbers and settings I liked and a few days later when I input those settings, the results are very different. Majority of the scripts that do repaint, when you add alerts to them, Trading view gives you a warning about it, I do not get a warning message on yours. This is very weird.

@CUBYC how were you able to figure out this script repaints?
השב
alexgrover juannoguerol
@juannoguerol, There might indeed be historical data overdependence, can be easily fixed, will work on it. Historical data overdependence isn't always taken into account with warning messages.
השב
juannoguerol alexgrover
@alexgrover, Thanks for the quick response, I can't wait to try an updated version - Like I mentioned, I got some really good results on my backtest. I was setting up a bunch of alerts and then hit a wall with the "historical data overdependence" as you mentioned. You and Lucia are very generous to share your hard work with everybody.
+1 השב
alexgrover juannoguerol
@juannoguerol, Srry about it, its a complicated matter, such indicators won't repaint if they don't recalculate on the entirety of the available data, and will only continue their calculation based on the precedent indicator value (which should be the case here hence my response on it shouldn't be repainting), however if the dataset change (which is the case in tradingview as older price values as discarded in order to have new data available) then adding the same indicator to the chart will produce different results. So i think one need to leave the indicator as it is, and never change the inputs (as it make the indicator recalculate on the entire dataset) and you won't see problems. I'll have to gather more information here, however as i said fixing the issue only take to update the indicator based on non historical overdependent events. So i'll try to fix it as quickly as possible.
השב
alexgrover juannoguerol
@juannoguerol, The repainting issue has been fixed.
השב
juannoguerol alexgrover
@alexgrover, woohoo! thank you very much, I'll give it a try then :-)
השב
בית סורק מניות סורק מט"ח סורק מטבעות-קריפטו יומן כלכלי איך זה עובד‏ תכונות גרף מחירון הפנה חבר חוקי הבית מרכז תמיכה כלים לאתרים וברוקרים יישומונים פתרונות גרפיים ספריית גרפים קלי משקל בלוג וחדשות טוויטר‏
פרופיל הגדרות פרופיל חשבון וחיוב הפנה חבר לשוניות התמיכה שלי מרכז תמיכה רעיונות שפורסמו עוקבים עוקב הודעות פרטיות צ'אט התנתק