ta.change
Measure how far a series moved over the last n bars, in its own units.
ta.change(source, length)source - source[length]: the change over length bars.
Parameters
A series parameter takes a value on every bar. A constant parameter must be known before the first bar, such as a number or an input.
| Name | Kind | Type | Default | Range | Description |
|---|---|---|---|---|---|
source | Series | number | - | - | The series to read. |
length | Constant | number | 1 | 1 to 10000 | Window in observed bars. |
Output
| Name | Type |
|---|---|
value | number |
Warm-up and missing values
- Warm-up
lengthbars. Names in the warm-up are this operator’s parameters.- Missing values
- na until
lengthbars of history exist, and na when either observation is na.
Example
ta.change(close, 1)plot(ta.change(close, 1), "Change")