Downloading...
PINE LIBRARY
Updated

utils

885
Library "utils"

ma_smooth(alg, src, len) Calculates various moving averages
  Parameters:
    alg: Smoothing algorithm to use [RMA, SMA, EMA, WMA]
    src: Source data
    len: Length of moving average
Release Notes
Update displayed chart
Release Notes
v3
Release Notes
v4

Added:
vma(alg, src, len) Calculates various moving averages
  Parameters:
    alg: Smoothing algorithm to use [RMA, SMA, EMA, WMA]
    src: Source data
    len: Length of moving average

Removed:
ma_smooth(alg, src, len) Calculates various moving averages
Release Notes
v5

Added:
sig(val) Clamps a value between 0 and 1 on a sigmoid curve
  Parameters:
    val: Input data

siga(val) Clamps a value between -1 and 1 on a sigmoid curve
  Parameters:
    val: Input data
Release Notes
v6

Added:
sigaw(val, weight)
  Clamps a series between -1 and 1 on a sigmoid curve with a tunable weight
  Parameters:
    val (float): Input series
    weight (float): Sigmoid weight

Updated:
vma(alg, src, len)
  Calculates various moving averages
  Parameters:
    alg (string): Smoothing algorithm to use (opt: ["SMA", "EMA", "RMA", "WMA", "DEMA", "TEMA", "VWMA", "HMA", "LSMA"])
    src (float): Source data
    len (simple int): Length of moving average

sig(val)
  Clamps a series between 0 and 1 on a sigmoid curve
  Parameters:
    val (float): Input series

siga(val)
  Clamps a series between -1 and 1 on a sigmoid curve
  Parameters:
    val (float): Input series

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.