Skip to content
AlertaChartAlertaScript / docs
AlertaScript / alerta.ta.kdj
On this pageSignatureParametersReturnsExample

Momentum / Reference

alerta.ta.kdj

TradingView-compatible spelling: ta.kdj, runs without warnings

Calculates the KDJ indicator.

alerta.ta.kdj(close, high, low, length, m1, m2) → [k, d, j]

Parameters

NameTypeRequiredDefaultDescription
closeseries floatYes—Close.
highseries floatYes—High.
lowseries floatYes—Low.
lengthintYes—n length.
m1intYes—m1 smooth.
m2intYes—m2 smooth.

Returns

[k, d, j]

Example

alerta.ta.kdj
[k, d, j] = kdj(close, high, low, 9, 3, 3)plot(k, { title: "K", color: color.blue, pane: "oscillator" })plot(d, { title: "D", color: color.orange, pane: "oscillator" })plot(j, { title: "J", color: color.purple, pane: "oscillator" })

Names and aliases

Guides and navigation are localized. Built-in reference descriptions and code examples are maintained in English.

AlertaScript

No results found.

Search by name, alias, or keyword.