PINE LIBRARY
تم تحديثه

NR_Versatilities

312
Library "NR_Versatilities"
Versatilities (aka, Versatile Utilities) includes:
- Seventeen Price Variants returned as a tuple,
- Eight Smoothing functions rolled into one,
- Pick any Past Value from any series with offset,
- Or just the previous value from any series.

pastVal(src, len)
  Fetches past value from src that came len distance ago
  Parameters:
    src (float): source series
    len (int): lookback distance - (optional) default is 1
  Returns: latest src if len <= 0, else src[len]

previous(src)
  Fetches past value from src that came len distance ago
  Parameters:
    src (float): source series
  Returns: previous value in the series if found, else current value

price_variants()
  Computes Several different averages using current and previous OHLC values
  Returns: Seventeen Uncommon Average Price Combinations

dynamic_MA(matyp, masrc, malen, lsmaoff, almasgm, almaoff, almaflr)
  Dynamically computes Eight different MAs on-demand individually, or an average of all taken together
  Parameters:
    matyp (string): pick one of these MAs - ALMA, EMA, HMA, LSMA, RMA, SMA, SWMA, WMA, ALL [= average of all MAs]
    masrc (float): source series to compute MA
    malen (simple int): lookback distance for MA
    lsmaoff (simple int): optional LSMA offset - default is 0
    almasgm (simple float): optional ALMA sigma - default is 5
    almaoff (simple float): optional ALMA offset - default is 0.5
    almaflr (simple bool): optional ALMA floor flag - default is false
  Returns: MA series for chosen type or, an average of all of them, if chosen so
ملاحظات الأخبار
v2

Updated:
pastVal(src, len)
  Fetches past value from src that came len distance ago
  Parameters:
    src (float): source series
    len (int): lookback distance - (optional) default is 1
  Returns: latest src if len <= 0, else src[len] (rounded-to-mintick)

price_variants()
  Computes Several different averages using current and previous OHLC values
  Returns: Map of Eighteen Uncommon Combinations of single and two-bar OHLC averages (rounded-to-mintick)

dynamic_MA(matyp, masrc, malen, lsmaoff, almasgm, almaoff, almaflr)
  Dynamically computes Eight different MAs on-demand individually, or an average of all taken together
  Parameters:
    matyp (string): pick one of these MAs - ALMA, EMA, HMA, LSMA, RMA, SMA, SWMA, WMA, ALL [= average of all MAs]
    masrc (float): source series to compute MA
    malen (simple int): lookback distance for MA
    lsmaoff (simple int): optional LSMA offset - default is 0
    almasgm (simple float): optional ALMA sigma - default is 5
    almaoff (simple float): optional ALMA offset - default is 0.5
    almaflr (simple bool): optional ALMA floor flag - default is false
  Returns: MA series for chosen type or, an average of all of them, if chosen so (rounded-to-mintick)
ملاحظات الأخبار
v3

Updated:
dynamic_MA(masrc, malen, lsmaoff, almasgm, almaoff, almaflr)
  Dynamically computes Eight different MAs and returns a Map containing Nine MAs
  Parameters:
    masrc (float): source series to compute MA
    malen (simple int): lookback distance for MA
    lsmaoff (simple int): optional LSMA offset - default is 0
    almasgm (simple float): optional ALMA sigma - default is 5
    almaoff (simple float): optional ALMA offset - default is 0.5
    almaflr (simple bool): optional ALMA floor flag - default is false
  Returns: Map of MAs - 'ALMA', 'EMA', 'HMA', 'LSMA', 'RMA', 'SMA', 'SWMA', 'WMA', 'ALL' (rounded-to-mintick)

إخلاء المسؤولية

لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.