Robust Weighting Oscillator


A simple oscillator using a modified lowess architecture, good in term of smoothness and reactivity.

Lowess Regression

Lowess or local regression is a non-parametric (can be used with data not fitting a normal distribution) smoothing method. This method fit a curve to the data using least squares.

In order to have a lowess regression one must use tricube kernel for the weightings w, the weightings are determined using a k-nearest-neighbor model.

lowess is then calculated like so :


Our indicator use G, a ,b and remove the square as well as replacing x by y


The oscillator is simple and nothing revolutionary but its still interesting to have new indicators.

Lowess would be a great method to be made on pinescript, i have an estimate but its not that good. Some codes use a simple line equation in order to estimate a lowess smoother, i can describe it as ax + b where a is a smooth oscillator, b some kind of filter defined by lp + bp with lp a smooth low pass filter and bp a bandpass filter, x is a variable dependent of the smoothing span.

Notas de Lançamento: Added G in a separate calculation mode, thanks to @ aaahopper for pointing it out. Changed color for downside movements.
Script de código aberto

No verdadeiro espírito TradingView, o autor deste script o publicou com código aberto, para que os traders possam compreendê-lo e verificá-lo. Um brinde ao autor! Você pode usá-lo gratuitamente, mas a reutilização deste código em uma publicação é regida pelas Regras da Casa. Você pode favoritá-lo para utilizá-lo em um gráfico.

Quer usar esse script no gráfico?

Become a Patreon and get access to exclusive technical indicators!

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


+3 Resposta
@nakg3, I undeserve this title ^^But i really appreciate your support as always
+1 Resposta
Hey, I think someone's requested for you to make an ARIMA on here before, I would also love something like that being public on TradingView. It would be a great addition to your other scripts.
+2 Resposta
alexgrover Taboozle
@Taboozle, I will try to work on that, thanks for the suggestion.
+1 Resposta
Awesome! Thanks for sharing!
+2 Resposta
alexgrover wroclai
@wroclai, I'm happy you like it, thanks for your support :)
+2 Resposta
Hi alexgrover,
What is line 13 used for?
'G' Seems to have no function or is there something missing?
Cheers :)

+1 Resposta
alexgrover aaahopper
@aaahopper, You are totally right, i have no idea why i did not included G in the final calculation, i will do some testing/modifying right now, sorry for the inconvenience.
aaahopper alexgrover
@alexgrover, No apology required. You don't owe us anything.
We appreciate your effort and generosity.
Thank you for again for this great work, which I truely appreciate :)
+1 Resposta
alexgrover aaahopper
@aaahopper, Thanks for the support and thanks for a lot for pointing the issue with G :) I hope i wont do any error in the future.