Built-in Functions
Structures
Built-in Variables and Constants
Conventions
Exchanges
talib.AD
Calculates the Chaikin A/D Line.
talib.AD(inPriceHLCV)Examples
Compute the Chaikin A/D Line from the latest K-lines.
javascript
function main() {
var records = exchange.GetRecords()
if (!records) return
var ret = talib.AD(records)
Log(ret)
}
python
import talib
def main():
records = exchange.GetRecords()
if not records:
return
ret = talib.AD(records.High, records.Low, records.Close, records.Volume)
Log(ret)Returns
| Type | Description |
numeric array | Indicator values, the same length as the input; the leading values without enough data are |
Arguments
| Name | Type | Required | Description |
inPriceHLCV |
| Yes | K-line array; the high, low, close and volume fields are used. In Python, pass |
See Also
Remarks
TA-Lib equivalent: AD(Records[High,Low,Close,Volume]) = Array(outReal).