QMA/SMA Difference


The quadratic moving average ( QMA ) or quadratic weighted moving average (QWMA) is a type of moving average who is closer to the price when price is up trending. This moving average is defined as the square root of the moving average of the squared price. The QMA-SMA difference use this moving average to provide a new volatility indicator who aim to be reactive and filter noisy volatility in order to only provide essential information.


This indicator is defined as the difference between a quadratic moving average and a simple moving average of same period. Since the QMA emphasize up movements and tend to be away from down movements she is always greater than the simple moving average , so a simple difference between those moving average provide our volatility indicator. Below is a comparison with a standard deviation and the indicator of both period 100.

Since its a difference between two moving average it can be interesting to use a simple moving as source for the standard deviation to provide another comparison

The standard deviation is smoother but still contain more information as well as having less reactivity.


I have a presented a new volatility indicator based on the quadratic moving average and compared it with a classic standard deviation. It is possible to change the power order of the QMA in order to provide different results, in order to do so you must also change the root, this is done in pine with : pow( sma (pow(close,w),length),1/w) where w is the power order, notice that an high power order can provide non attributed values.
Open-source Skript

Ganz im Sinne von TradingView hat der Autor dieses Skripts es als Open-Source veröffentlicht, damit Trader es verstehen und überprüfen können. Ein Hoch auf den Autor! Sie können es kostenlos verwenden, aber die Wiederverwendung dieses Codes in einer Publikation unterliegt den Hausregeln. Sie können das Skript den Favoriten hinzufügen, um es auf dem Chart zu verwenden.

Möchten Sie dieses Skript auf einem Chart verwenden?

Become a Patreon and get access to exclusive technical indicators!

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


Another beautiful haiku by Alex.
+2 Antworten
@LucF, Thank you very much for the support, i really like the comparison :)
nice :)
+2 Antworten
alexgrover ballofpaper
@ballofpaper, Glad you like it, as always thank you very much for the support, i appreciate it :)
+1 Antworten
Thak you again
+1 Antworten
alexgrover aaahopper
@aaahopper, You are more than welcome :)