Traders_Endeavors

Simple Volatility Momentum

Overview:
The Simple Volatility Momentum indicator calculates the mean and standard deviation of the changes of price (returns) using various types of moving averages (Incremental, Rolling, and Exponential). With quantifying the dispersion of price data around the mean, statistical insights are provided on the volatility and the movements of price and returns. The indicator also ranks the mean absolute value of the changes of price over a specified time period which helps you assess the strength of the "trend" and "momentum" regardless of the direction of returns.


Simple Volatility Momentum
This indicator can be used for mean reversion strategies and "momentum" or trend based strategies.

The indicator calculates the average return as the momentum metric and then gets the moving average of the average return and standard deviations from average return average. On the options you can determine if you want to use 1 or 2 standard deviation bands or have both of them enabled.

Settings:
  1. Source: By default it's at close.
  2. M Length: This is the length of the "momentum".
  3. Rank Length: This is the length of the rank calculation of absolute value of the average return
  4. MA Type: This is the different type of calculations for the mean and standard deviation. By default its at incremental.
  5. Smoothing factor: (Only used if you choose the exponential MA type.)

The absolute value of the average return helps you see the strength of the "momentum" and trend. If there is a low ranking of the absolute value of the average return then you can eventually expect it to increase which means that the average return is trending, leading to trending price moves. If the Mean ABS rank value is at or near the maximum value 100 and the average return is at -2 standard deviation from the mean, you can see it as the negative momentum or trend being "finished". Similarly, if the Mean ABS value is near or at the maximum value 100 and the average return is at +2 standard deviation from the mean, you can view the uptrend, as "finished" and the Mean ABS rank can't really go higher than 100.

Moving Average Calculations type:
  • Incremental: Incremental moving averages use an incremental approach to update the moving average by adding the newest data point and subtracting the oldest one.

  • Exponential: The exponential moving average gives more weight to recent data points while still considering older ones. This is achieved by applying a smooth factor to the previous EMA value and the current data point. EMA's react more quickly to recent changes in the data compared to simple moving averages, making them useful for short term trends and momentum in financial markets.

  • Rolling: The moving average is calculated by taking the average of a fixed number of data points within a defined window. As new data becomes available, the window moves forward and the average is recalculated. Rolling Moving Averages are useful for smoothing out short-fluctuations and identifying trends over time.

Important thing to note about indicators involving bands and "momentum" or "trend" or prices:
For the explanation we will assume that stock returns follow a normal distribution and price follows a log normal distribution. Please note that in the live market this assumption isn't always true. Many people incorrectly use standard deviations on prices and trade them as mean reversion strategies or overbought or oversold levels which is not what standard deviations are meant for. Assuming you have applied the log transformation on the standard deviation bands (if your input is raw price then you should use a log transformation to remove the skewness of price), and you have a range of 2 standard deviations from the mean, under the empirical rule with enough occurrences 95% of the values will be within the 2 standard deviation range. This doesn't mean that if price falls to the bottom of the 2 standard deviation bound, there is a 95% chance it will revert back to mean, this is incorrect and not how standard deviations or mean reversion works.


"MOMENTUM"
In finance "momentum" refers to the rate of change of a time series data point. It shows the persistence or tendency for a data series to continue moving in its current direction. In finance, "momentum" based strategies capitalize on the observed tendency of assets that have performed well (or poorly) in the recent past to continue performing well (or poorly) in the near future. This persistence is often observed in various financial instruments including stocks, currencies and commodities.

"Momentum" is commonly calculated with the average return, and relies on the assumption that assets with positive "momentum" or a positive average return will likely continue to perform well in the short to medium term, while assets with a negative average return are expected to continue underperforming. This average return or expected value is derived from historical observations and statistical analysis of previous price movements. However, real markets are subject to levels of efficiencies, market fluctuations, randomness, and may not always produce consistent returns over time involving momentum based strategies.

Mean Reversion:
In finance, the average return is an important parameter in mean reversion strategies. Using statistical methodologies, mean reversion strategies aim to exploit the deviations from the historical average return by identifying instances where current prices and their changes diverge from their expected levels based on past performance. This approach involves statistical analysis and predictive modelling techniques to check where and when the average rate of change is likely to revert towards the mean. It's important to know that mean reversion is a temporary state and will not always be present in a specific timeseries.

Using the average return over price offers several advantages in finance and trading since it is less sensitive to extreme price movements or outliers compared to raw price data. Price itself contains a distribution that is usually positively-skewed and has no upper bound. Mean reversion typically occurs in distributions where extreme values are followed by a tendency for the variable to return towards its mean over time, however the probability distribution of price has no tendency for values to revert towards any specific level. Instead, values may continue to increase without a bound. Returns themself contain more stationary behavior than price levels. Mean reversion strategies rely on the assumption that deviations from the mean will eventually revert back to the mean. Returns, being more likely to exhibit stationary, are better suited for mean reversion based strategies.

The distribution of returns are often more symmetrically distributed around their mean compared to price distributions. This symmetry makes it easier to identify deviations from the mean and assess the likelihood of mean reversion occurrence. Returns are also less sensitive to trends and long-term price movements compared to price levels. Mean reversion strategies aim to exploit deviations from mean, which can be obscured when analyzing raw price data since raw price is almost always trending. Returns can filter out the trend component of price movements, making it easier to identify opportunities.

Stationary Process: Implication that properties like mean and variance remain relatively constant over time.


Invite-only script

Access to this script is restricted to users authorized by the author and usually requires payment. You can add it to your favorites, but you will only be able to use it after requesting permission and obtaining it from its author. Contact Traders_Endeavors for more information, or follow the author's instructions below.

TradingView does not suggest paying for a script and using it unless you 100% trust its author and understand how the script works. In many cases you can find a good open-source alternative for free in our Community Scripts.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.

Author's instructions

Access this indicator here: www.patreon.com/user?u=80987417...

Want to use this script on a chart?

Warning: please read before requesting access.