Lipi Reference Lipi

Functions

talib.swma()

Symmetrically weighted moving average with fixed length: 4. Weights: [1/6, 2/6, 2/6, 1/6].

Syntax

                talib.swma(series float source) → series float
              

Arguments

source required series float Source series.

Return Type

series float

Example


          indicator("Symmetric Weighted Moving Average (SWMA)", overlay=true)
length = input(10, "SWMA Length")
swmaValue = talib.swma(close)
plot(swmaValue, color=color.blue, title="SWMA")