mom
Change (Difference from historical value)
mom(source, length)
Parameters
| Name | Type | Description |
|---|---|---|
source |
field | Data series |
length |
int | Periods to look back |
Formula
```
change = source - source[length]
```
Examples
change(close, 1) > 0; // positive gain from prior bar
change(high, 5); < 0 // lower high from 5 bars ago
change(volume, 10) >= volume[10]; // volume more than doubled from 10 bars ago
Returns
Float (positive = increase, negative = decrease)