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
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
close | series float | Yes | — | Close. |
high | series float | Yes | — | High. |
low | series float | Yes | — | Low. |
length | int | Yes | — | n length. |
m1 | int | Yes | — | m1 smooth. |
m2 | int | Yes | — | 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.