PINE LIBRARY

ta

Cập nhật
Library "ta"


█ OVERVIEW

This library holds technical ​analysis functions calculating values for which no Pine built-in exists.


Look first. Then leap.



█ FUNCTIONS

cagr(entryTime, entryPrice, exitTime, exitPrice)
It calculates the "Compound Annual Growth Rate" between two points in time. The ​CAGR is a notional, annualized growth rate that assumes all profits are reinvested. It only takes into account the prices of the two end points — not drawdowns, so it does not calculate risk. It can be used as a yardstick to compare the performance of two instruments. Because it annualizes values, the function requires a minimum of one day between the two end points (annualizing returns over smaller periods of times doesn't produce very meaningful figures).
  Parameters:
    entryTime: The starting timestamp.
    entryPrice: The starting point's price.
    exitTime: The ending timestamp.
    exitPrice: The ending point's price.
  Returns: ​CAGR in % (50 is 50%). Returns `na` if there is not >=1D between `entryTime` and `exitTime`, or until the two time points have not been reached by the script.



█ v2, Mar. 8, 2022


Added functions `allTimeHigh()` and `allTimeLow()` to find the highest or lowest value of a source from the first historical bar to the current bar. These functions will not look ahead; they will only return new highs/lows on the bar where they occur.

allTimeHigh(​src)
Tracks the highest value of `src` from the first historical bar to the current bar.
  Parameters:
    src: (series int/float) Series to track. Optional. The default is `high`.
  Returns: (float) The highest value tracked.

allTimeLow(​src)
Tracks the lowest value of `src` from the first historical bar to the current bar.
  Parameters:
    src: (series int/float) Series to track. Optional. The default is `low`.
  Returns: (float) The lowest value tracked.



█ v3, Sept. 27, 2022


This version includes the following new functions:

aroon(length)
  Calculates the values of the Aroon indicator.
  Parameters:
    length (simple int): (simple int) Number of bars (length).
  Returns: ([][float, float[]]) A tuple of the Aroon-Up and Aroon-Down values.

coppock(source, longLength, shortLength, smoothLength)
  Calculates the value of the Coppock Curve indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
    longLength (simple int): (simple int) Number of bars for the fast ROC value (length).
    shortLength (simple int): (simple int) Number of bars for the slow ROC value (length).
    smoothLength (simple int): (simple int) Number of bars for the weigted moving average value (length).
  Returns: (float) The oscillator value.

dema(source, length)
  Calculates the value of the Double Exponential Moving Average (DEMA).
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The double exponentially weighted moving average of the `source`.

d​ema2(​src, length)
  An alternate ​Double Exponential ​Moving Average (D​ema) function to `d​ema()`, which allows a "series float" length argument.
  Parameters:
    ​src: (series int/float) Series of values to process.
    length: (series int/float) Length for the smoothing parameter calculation.
  Returns: (float) The double exponentially ​weighted moving average of the `​src`.

dm(length)
  Calculates the value of the "Demarker" indicator.
  Parameters:
    length (simple int): (simple int) Number of bars (length).
  Returns: (float) The oscillator value.

donchian(length)
  Calculates the values of a Donchian Channel using `high` and `low` over a given `length`.
  Parameters:
    length (int): (series int) Number of bars (length).
  Returns: ([][float, float, float[]]) A tuple containing the channel high, low, and median, respectively.

​ema2(​src, length)
  An alternate ​ema function to the `ta.​ema()` built-in, which allows a "series float" length argument.
  Parameters:
    ​src: (series int/float) Series of values to process.
    length: (series int/float) Number of bars (length).
  Returns: (float) The exponentially ​weighted moving average of the `​src`.

eom(length, div)
  Calculates the value of the Ease of Movement indicator.
  Parameters:
    length (simple int): (simple int) Number of bars (length).
    div (simple int): (simple int) Divisor used for normalzing values. Optional. The default is 10000.
  Returns: (float) The oscillator value.

frama(source, length)
  The Fractal Adaptive Moving Average (FRAMA), developed by John Ehlers, is an adaptive moving average that dynamically adjusts its lookback period based on fractal geometry.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (int): (series int) Number of bars (length).
  Returns: (float) The fractal adaptive moving average of the `source`.

ft(source, length)
  Calculates the value of the Fisher Transform indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Number of bars (length).
  Returns: (float) The oscillator value.

ht(source)
  Calculates the value of the Hilbert Transform indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
  Returns: (float) The oscillator value.

ichimoku(conLength, baseLength, senkouLength)
  Calculates values of the Ichimoku Cloud indicator, including tenkan, kijun, senkouSpan1, senkouSpan2, and chikou. NOTE: offsets forward or backward can be done using the `offset` argument in `plot()`.
  Parameters:
    conLength (int): (series int) Length for the Conversion Line (Tenkan). The default is 9 periods, which returns the mid-point of the 9 period Donchian Channel.
    baseLength (int): (series int) Length for the Base Line (Kijun-sen). The default is 26 periods, which returns the mid-point of the 26 period Donchian Channel.
    senkouLength (int): (series int) Length for the Senkou Span 2 (Leading Span B). The default is 52 periods, which returns the mid-point of the 52 period Donchian Channel.
  Returns: ([][float, float, float, float, float[]]) A tuple of the Tenkan, Kijun, Senkou Span 1, Senkou Span 2, and Chikou Span values. NOTE: by default, the senkouSpan1 and senkouSpan2 should be plotted 26 periods in the future, and the Chikou Span plotted 26 days in the past.

ift(source)
  Calculates the value of the Inverse Fisher Transform indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
  Returns: (float) The oscillator value.

kvo(fastLen, slowLen, trigLen)
  Calculates the values of the Klinger Volume Oscillator.
  Parameters:
    fastLen (simple int): (simple int) Length for the fast moving average smoothing parameter calculation.
    slowLen (simple int): (simple int) Length for the slow moving average smoothing parameter calculation.
    trigLen (simple int): (simple int) Length for the trigger moving average smoothing parameter calculation.
  Returns: ([][float, float[]]) A tuple of the KVO value, and the trigger value.

pzo(length)
  Calculates the value of the Price Zone Oscillator.
  Parameters:
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The oscillator value.

rms(source, length)
  Calculates the Root Mean Square of the `source` over the `length`.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (int): (series int) Number of bars (length).
  Returns: (float) The RMS value.

rwi(length)
  Calculates the values of the Random Walk Index.
  Parameters:
    length (simple int): (simple int) Lookback and ATR smoothing parameter length.
  Returns: ([][float, float[]]) A tuple of the `rwiHigh` and `rwiLow` values.

stc(source, fast, slow, cycle, d1, d2)
  Calculates the value of the Schaff Trend Cycle indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
    fast (simple int): (simple int) Length for the MACD fast smoothing parameter calculation.
    slow (simple int): (simple int) Length for the MACD slow smoothing parameter calculation.
    cycle (simple int): (simple int) Number of bars for the Stochastic values (length).
    d1 (simple int): (simple int) Length for the initial %D smoothing parameter calculation.
    d2 (simple int): (simple int) Length for the final %D smoothing parameter calculation.
  Returns: (float) The oscillator value.

stochFull(periodK, smoothK, periodD)
  Calculates the %K and %D values of the Full Stochastic indicator.
  Parameters:
    periodK (simple int): (simple int) Number of bars for Stochastic calculation. (length).
    smoothK (simple int): (simple int) Number of bars for smoothing of the %K value (length).
    periodD (simple int): (simple int) Number of bars for smoothing of the %D value (length).
  Returns: ([][float, float[]]) A tuple of the slow %K and the %D moving average values.

stochRsi(lengthRsi, periodK, smoothK, periodD, source)
  Calculates the %K and %D values of the Stochastic RSI indicator.
  Parameters:
    lengthRsi (simple int): (simple int) Length for the RSI smoothing parameter calculation.
    periodK (simple int): (simple int) Number of bars for Stochastic calculation. (length).
    smoothK (simple int): (simple int) Number of bars for smoothing of the %K value (length).
    periodD (simple int): (simple int) Number of bars for smoothing of the %D value (length).
    source (float): (series int/float) Series of values to process. Optional. The default is `close`.
  Returns: ([][float, float[]]) A tuple of the slow %K and the %D moving average values.

supertrend(factor, atrLength, wicks)
  Calculates the values of the SuperTrend indicator with the ability to take candle wicks into account, rather than only the closing price.
  Parameters:
    factor (float): (series int/float) Multiplier for the ATR value.
    atrLength (simple int): (simple int) Length for the ATR smoothing parameter calculation.
    wicks (simple bool): (simple bool) Condition to determine whether to take candle wicks into account when reversing trend, or to use the close price. Optional. Default is false.
  Returns: ([][float, int[]]) A tuple of the superTrend value and trend direction.

szo(source, length)
  Calculates the value of the Sentiment Zone Oscillator.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The oscillator value.

t3(source, length, vf)
  Calculates the value of the Tilson Moving Average (T3).
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Length for the smoothing parameter calculation.
    vf (simple float): (simple float) Volume factor. Affects the responsiveness.
  Returns: (float) The Tilson moving average of the `source`.

t3Alt(source, length, vf)
  An alternate Tilson Moving Average (T3) function to `t3()`, which allows a "series float" `length` argument.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (float): (series int/float) Length for the smoothing parameter calculation.
    vf (simple float): (simple float) Volume factor. Affects the responsiveness.
  Returns: (float) The Tilson moving average of the `source`.

tema(source, length)
  Calculates the value of the Triple Exponential Moving Average (TEMA).
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The triple exponentially weighted moving average of the `source`.

tema2(source, length)
  An alternate Triple Exponential Moving Average (TEMA) function to `tema()`, which allows a "series float" `length` argument.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (float): (series int/float) Length for the smoothing parameter calculation.
  Returns: (float) The triple exponentially weighted moving average of the `source`.

trima(source, length)
  Calculates the value of the Triangular Moving Average (TRIMA).
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (int): (series int) Number of bars (length).
  Returns: (float) The triangular moving average of the `source`.

trima2(​src, length)
  An alternate Triangular ​Moving Average (TRIMA) function to `trima()`, which allows a "series int" length argument.
  Parameters:
    ​src: (series int/float) Series of values to process.
    length: (series int) Number of bars (length).
  Returns: (float) The triangular moving average of the `​src`.

trix(source, length, signalLength, exponential)
  Calculates the values of the TRIX indicator.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Length for the smoothing parameter calculation.
    signalLength (simple int): (simple int) Length for smoothing the signal line.
    exponential (simple bool): (simple bool) Condition to determine whether exponential or simple smoothing is used. Optional. The default is `true` (exponential smoothing).
  Returns: ([][float, float, float[]]) A tuple of the TRIX value, the signal value, and the histogram.

uo(fastLen, midLen, slowLen)
  Calculates the value of the Ultimate Oscillator.
  Parameters:
    fastLen (simple int): (series int) Number of bars for the fast smoothing average (length).
    midLen (simple int): (series int) Number of bars for the middle smoothing average (length).
    slowLen (simple int): (series int) Number of bars for the slow smoothing average (length).
  Returns: (float) The oscillator value.

vhf(source, length)
  Calculates the value of the Vertical Horizontal Filter.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (simple int): (simple int) Number of bars (length).
  Returns: (float) The oscillator value.

vi(length)
  Calculates the values of the Vortex Indicator.
  Parameters:
    length (simple int): (simple int) Number of bars (length).
  Returns: ([][float, float[]]) A tuple of the viPlus and viMinus values.

vzo(length)
  Calculates the value of the Volume Zone Oscillator.
  Parameters:
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The oscillator value.

williamsFractal(period)
  Detects Williams Fractals.
  Parameters:
    period (int): (series int) Number of bars (length).
  Returns: ([][bool, bool[]]) A tuple of an up fractal and down fractal. Variables are true when detected.

wpo(length)
  Calculates the value of the Wave Period Oscillator.
  Parameters:
    length (simple int): (simple int) Length for the smoothing parameter calculation.
  Returns: (float) The oscillator value.


█ v7, Nov. 2, 2023


This version includes the following new and updated functions:

atr2(length)
  An alternate ATR function to the `ta.atr()` built-in, which allows a "series float" `length` argument.
  Parameters:
    length (float): (series int/float) Length for the smoothing parameter calculation.
  Returns: (float) The ATR value.

changePercent(newValue, oldValue)
  Calculates the percentage difference between two distinct values.
  Parameters:
    newValue (float): (series int/float) The current value.
    oldValue (float): (series int/float) The previous value.
  Returns: (float) The percentage change from the `oldValue` to the `newValue`.

donchian(length)
  Calculates the values of a Donchian Channel using `high` and `low` over a given `length`.
  Parameters:
    length (int): (series int) Number of bars (length).
  Returns: ([][float, float, float[]]) A tuple containing the channel high, low, and median, respectively.

highestSince(cond, source)
  Tracks the highest value of a series since the last occurrence of a condition.
  Parameters:
    cond (bool): (series bool) A condition which, when `true`, resets the tracking of the highest `source`.
    source (float): (series int/float) Series of values to process. Optional. The default is `high`.
  Returns: (float) The highest `source` value since the last time the `cond` was `true`.

lowestSince(cond, source)
  Tracks the lowest value of a series since the last occurrence of a condition.
  Parameters:
    cond (bool): (series bool) A condition which, when `true`, resets the tracking of the lowest `source`.
    source (float): (series int/float) Series of values to process. Optional. The default is `low`.
  Returns: (float) The lowest `source` value since the last time the `cond` was `true`.

relativeVolume(length, anchorTimeframe, isCumulative, adjustRealtime)
  Calculates the volume since the last change in the time value from the `anchorTimeframe`, the historical average volume using bars from past periods that have the same relative time offset as the current bar from the start of its period, and the ratio of these volumes. The volume values are cumulative by default, but can be adjusted to non-accumulated with the `isCumulative` parameter.
  Parameters:
    length (simple int): (simple int) The number of periods to use for the historical average calculation.
    anchorTimeframe (simple string): (simple string) The anchor timeframe used in the calculation. Optional. Default is "D".
    isCumulative (simple bool): (simple bool) If `true`, the volume values will be accumulated since the start of the last `anchorTimeframe`. If `false`, values will be used without accumulation. Optional. The default is `true`.
    adjustRealtime (simple bool): (simple bool) If `true`, estimates the cumulative value on unclosed bars based on the data since the last `anchor` condition. Optional. The default is `false`.
  Returns: ([][float, float, float[]]) A tuple of three float values. The first element is the current volume. The second is the average of volumes at equivalent time offsets from past anchors over the specified number of periods. The third is the ratio of the current volume to the historical average volume.

rma2(source, length)
  An alternate RMA function to the `ta.rma()` built-in, which allows a "series float" `length` argument.
  Parameters:
    source (float): (series int/float) Series of values to process.
    length (float): (series int/float) Length for the smoothing parameter calculation.
  Returns: (float) The rolling moving average of the `source`.

supertrend2(factor, atrLength, wicks)
  An alternate SuperTrend function to `supertrend()`, which allows a "series float" `atrLength` argument.
  Parameters:
    factor (float): (series int/float) Multiplier for the ATR value.
    atrLength (float): (series int/float) Length for the ATR smoothing parameter calculation.
    wicks (simple bool): (simple bool) Condition to determine whether to take candle wicks into account when reversing trend, or to use the close price. Optional. Default is `false`.
  Returns: ([][float, int[]]) A tuple of the superTrend value and trend direction.

vStop(source, atrLength, atrFactor)
  Calculates an ATR-based stop value that trails behind the `source`. Can serve as a possible stop-loss guide and trend identifier.
  Parameters:
    source (float): (series int/float) Series of values that the stop trails behind.
    atrLength (simple int): (simple int) Length for the ATR smoothing parameter calculation.
    atrFactor (float): (series int/float) The multiplier of the ATR value. Affects the maximum distance between the stop and the `source` value. A value of 1 means the maximum distance is 100% of the ATR value. Optional. The default is 1.
  Returns: ([][float, bool[]]) A tuple of the volatility stop value and the trend direction as a "bool".

vStop2(source, atrLength, atrFactor)
  An alternate Volatility Stop function to `vStop()`, which allows a "series float" `atrLength` argument.
  Parameters:
    source (float): (series int/float) Series of values that the stop trails behind.
    atrLength (float): (series int/float) Length for the ATR smoothing parameter calculation.
    atrFactor (float): (series int/float) The multiplier of the ATR value. Affects the maximum distance between the stop and the `source` value. A value of 1 means the maximum distance is 100% of the ATR value. Optional. The default is 1.
  Returns: ([][float, bool[]]) A tuple of the volatility stop value and the trend direction as a "bool".


Removed Functions:

allTimeHigh(src)
  Tracks the highest value of `src` from the first historical bar to the current bar.

allTimeLow(src)
  Tracks the lowest value of `src` from the first historical bar to the current bar.

trima2(src, length)
  An alternate Triangular Moving Average (TRIMA) function to `trima()`, which allows a
"series int" length argument.

Phát hành các Ghi chú
A myriad of new technical ​analysis functions have been added. The original release documentation has been edited with the new functions under the "v3" section.

Credit goes to everget for large portions of the updated code. Thank you for your valuable contributions.
Phát hành các Ghi chú
v4

Updated `aroon()` calculation to match the built-in indicator values.
Phát hành các Ghi chú
v5

The ​Ultimate Oscillator function has been fixed to correctly return `na` on early bars before a value is rendered. In addition, a function for the ​Awesome Oscillator has been implemented:


ao(src, shortLength, longLength)
  Calculates the value of the ​Awesome Oscillator.
  Parameters:
    src
    shortLength: (series int) Number of bars for the fast moving average (length).
    longLength: (series int) Number of bars for the slow moving average (length).
  Returns: (float) The oscillator value.
Phát hành các Ghi chú
v6

We've added a new function to calculate and compare either cumulative or non-cumulative volume within a period and its average at equivalent time offsets over a specified number of periods. This addition utilizes our recently-published RelativeValue library.


relativeVolume(length, anchorTimeframe, isCumulative)
  Calculates the volume since the last change in the time value from the `anchorTimeframe`, the historical average of values at equivalent offsets from previous period anchors, and the ratio of these volumes. The volume values are cumulative by default, but can be set to non-accumulated values with the `isCumulative` parameter.
  Parameters:
    length (simple int): The number of historical periods to use in the average.
    anchorTimeframe (simple string): The anchor timeframe used in the calculation. Optional. Default is "D".
    isCumulative (simple bool): If `true`, the volume values will be accumulated since the start of the last `anchorTimeframe`. If `false`, values will be used without accumulation. Optional. The default is `true`.
  Returns: ([][float, float, float[]]) A tuple of three float values. The first element is the current volume. The second is the average of volumes at equivalent time offsets from past anchors over the specified number of periods. The third is the ratio of the current volume to the historical average volume.

Phát hành các Ghi chú
v7

This version's release includes the following changes:

 • Enhanced the `relativeVolume()` function.
 • Introduced eight new functions.
 • Updated the `donchian()` function to return a tuple containing all Donchian Channel values.
 • Deprecated the `allTimeHigh()` and `allTimeLow()` functions due to the availability of the more optimal ta.max() and ta.min() built-in functions, which respectively calculate the all-time highest and lowest values of a series.
 • Deprecated the `trima2()` function, as `trima()` now accepts a "series int" `length` argument.
 • Organized the functions in approximate alphabetical order.
 • We've refined the library's code comments and annotations for clarity and readability.

For more details on this version's changes, please see below.



█  ENHANCEMENTS


relativeVolume():
 • Updated to utilize the latest version of the RelativeValue library, integrating the new `averageAtTime()` overload to rectify calculation discrepancies on symbols with irregular session opening times.
 • Introduced an `adjustRealtime` parameter. When activated in cumulative mode, it allows a predictive estimation of the hypothetical closing value for in-progress bars based on accumulated data.



█  NEW FUNCTIONS


We've added the following functions to the library:

 • atr2(): An alternate ATR function to the ta.atr() built-in, which allows a "series float" `length` argument.
 • changePercent(): Calculates the percentage difference between two distinct values.
 • highestSince(): Tracks the highest value of a series since the last occurrence of a condition.
 • lowestSince(): Tracks the lowest value of a series since the last occurrence of a condition.
 • rma2(): An alternate RMA function to the ta.rma() built-in, which allows a "series float" `length` argument.
 • supertrend2(): An alternate SuperTrend function to `supertrend()`, which allows a "series float" `atrLength` argument.
 • vStop(): Calculates a volatility-adjusted stop value based on the ATR, potentially serving as a trailing stop loss or trend detection tool.
 • vStop2(): An alternate Volatility Stop function to `vStop()`, which allows a "series float" `atrLength` argument.


The original release documentation has been edited with complete documentation for the updated, added, and removed functions under the "v7" section.


Phát hành các Ghi chú
v8

This version release contains two new functions that utilize dynamic requests to fetch intrabar volume and price information. These functions use this information to calculate Up/Down Volume, Volume Delta, and Cumulative Volume Delta values:

requestUpAndDownVolume(lowerTimeframe)
  Requests data from a specified `lowerTimeframe` and categorizes the `volume` of each intrabar within the chart bar as positive (up) or negative (down). The function uses this polarized volume data to calculate the chart bar's total positive volume, total negative volume, and Volume Delta.
Note that calls to this function count toward a script's `request.*()` call limit.
  Parameters:
    lowerTimeframe (string): The timeframe of the requested intrabar data. Accepts a valid timeframe string (e.g., "5", "15", "1D"), an empty string, or `timeframe.period`. Smaller timeframes provide higher precision but cover fewer chart bars. Higher timeframes offer more chart bar coverage with less granularity. If the specified timeframe is higher than the chart's, it causes a runtime error.
  Returns: ([float, float, float]) A tuple containing the following:
- The total positive (up) intrabar volume within the chart bar.
- The total negative (down) intrabar volume within the chart bar.
- The volume delta, i.e., the net difference between up and down volume.

requestVolumeDelta(lowerTimeframe, cumulativePeriod)
  Requests data from a specified `lowerTimeframe` and categorizes the `volume` of each intrabar within the chart bar as positive (up) or negative (down). The function uses this information to calculate the bar's Volume Delta, i.e., the difference between the total up and down intrabar volume.
If the call specifies a `cumulativePeriod` argument higher than the chart's timeframe, it calculates the Cumulative Volume Delta (CVD), which is a running sum of Volume Delta across all bars within the period. In addition, it tracks the highest and lowest CVD values calculated within each bar over the period. The sum and highest/lowest values reset when a new period starts.
Note that calls to this function count toward a script's `request.*()` call limit.
  Parameters:
    lowerTimeframe (string): The timeframe of the requested intrabar data. Accepts a valid timeframe string (e.g., "5", "15", "1D"), an empty string, or `timeframe.period`. Smaller timeframes provide higher precision but cover fewer chart bars. Higher timeframes offer more chart bar coverage with less granularity. If the specified timeframe is higher than the chart's, it causes a runtime error.
    cumulativePeriod (string): Determines the size of the CVD period. Accepts a valid timeframe string (e.g., "5", "15", "1D"), an empty string, or `timeframe.period`. The calculations reset after a new period starts. For example, a value of "1D" means that the function accumulates and tracks the values from each chart bar within a "1D" period and resets at the open of a new "1D" bar.
  Returns: ([float, float, float, float]) A tuple containing the following:
- The opening Volume Delta/CVD at the start of each chart bar. This value is always 0 when a new `cumulativePeriod` starts.
- The maximum Volume Delta/CVD within the current `cumulativePeriod`.
- The minimum Volume Delta/CVD within the current `cumulativePeriod`.
- The current Volume Delta/CVD value.


Phát hành các Ghi chú
v9

We have upgraded this library to Pine Script™ v6, ensuring compatibility with the latest features and improvements. See the Release notes and Migration guide to learn what's new in v6 and how to convert your scripts to this version.
indicatorslibrarytalibtechindicator

Thư viện Pine

Theo tinh thần TradingView thực sự, tác giả đã xuất bản mã Pine này dưới dạng thư viện nguồn mở để các lập trình viên Pine khác trong cộng đồng của chúng tôi có thể sử dụng lại. Chúc mừng tác giả! Bạn có thể sử dụng thư viện này riêng tư hoặc trong các bài đăng nguồn mở khác. Tuy nhiên, bạn cần sử dụng lại mã này theo Quy tắc nội bộ.


Share TradingView with a friend:
tradingview.com/share-your-love/

Read more about the new tools and features we're building for you: tradingview.com/blog/en/
Ngoài ra, trên:

Thông báo miễn trừ trách nhiệm