Money flow index
RSI built from price times volume, from 0 to 100.
Inputs
| Name | Type | Default | Range |
|---|---|---|---|
| period | int | 14 | 1 to 5000 |
| volume | volume | tick |
Outputs
| Name | Type | Required | Description |
|---|---|---|---|
| mfi | value | Optional | color theme.accent, style line, width 1 |
- Warm-up
- period bars (14 at the defaults)
- Repaints
- No
- Parity
- TA-Lib, within 1e-9
Formula
The typical price times volume is positive flow on a bar whose typical price rose and negative flow on one that fell; it counts in neither when it did not move
MFI = 100 * positive / (positive + negative) over the last period bars
Only positive flow reads 100, no flow reads 50.