Average True Range Node
ATR — Separate High / Low / Close Inputs
Overview
The Average True Range Node computes ATR from three independently connected series: High, Low, and Close. Unlike the standard ATR node that reads directly from a stock source, this variant lets you wire any three numeric output series as High, Low, and Close inputs — enabling ATR calculations on transformed or synthesised price streams.
The underlying algorithm is identical to the standard ATR: True Range is computed per bar and then smoothed using Wilder's exponential smoothing over the chosen period. The first value is a simple average of the first period true ranges; every subsequent value is updated via Wilder's formula.
Formula
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| period | number | 14 | Smoothing period for Wilder's ATR calculation. Common values: 7, 10, 14, 20. |
Inputs & Outputs
| Slot | Direction | Type | Description |
|---|---|---|---|
| input1 | Input | (number | null)[] | High price series |
| input2 | Input | (number | null)[] | Low price series |
| input3 | Input | (number | null)[] | Close price series |
| values | Output | (number | null)[] | ATR values; first (period − 1) entries are null |
| timestamps | Output | number[] | Unix timestamps aligned to the input series |
All three inputs are required. Connect separate High, Low, and Close series nodes toinput1, input2, and input3 respectively. The node will report an error if any slot is disconnected.
Use Cases
Transformed Price Streams
Apply ATR to adjusted or synthetic High/Low/Close series without changing the underlying data source.
Stop-Loss Sizing on Custom Data
Feed cleaned or spread-adjusted H/L/C into this node to compute position-size-aware stops.
Multi-Asset Volatility Comparison
Wire H/L/C from different instruments to compare their ATR on the same chart.
Tips & Best Practices
📐 Series Length
All three input series must have the same length. Mismatched lengths are trimmed to the shortest.
⚡ Wilder Lag
Wilder's smoothing is slower to respond than EMA. Use a shorter period (7–10) for fast-moving markets.
🔗 vs Standard ATR
If your data comes from a single stock source node, prefer the standard ATR node — it is more efficient and requires no manual wiring.