The Return to the Mean Oscillator shows the spread between the selected mean study and the actual close in price.
In this first version, I'm including the All-Time Historical Mean, which is the evolution of the mean value of that asset since its inception.
By using this indicator we are able to see if a particular market is trading above/below historical mean value.
The Mean value equals zero in the oscillator scale.
Therefore, we can use this indicator to clearly identify 'Return to the Mean' moves.
Note: Tradingview limits the number of candles we can use on each time frame.
Depending on the deepness of historical data, it is possible that the mean value could miss old data and therefore plot different levels for each timeframe.
That is especially true for markets with a long history or when we calculate it for intraday time frames.
In case of doubt, refer to the mean value at higher time frames.