talib.bbw
Bollinger band width: the same calculation as talib.bb, delivered as one number instead of three bands.
Its arguments match talib.bb exactly, including mult being an int.
talib.bbw(series float source, series int length, series int mult) → series float| Parameter | Type | Required | Description |
|---|---|---|---|
source | series float | yes | The series the bands are built on. |
length | series int | yes | How many bars the calculation covers. |
mult | series int | yes | Band multiplier. An int, not a float: a fractional multiplier is refused when the script is checked, and there is no rounding. |
Returns series float — A single series float: the width.
indicator("Bollinger band width")
plot(talib.bbw(close, 20, 2))See also talib.alma · talib.atr · talib.barssince
Part of the function index.
Ready to put this into practice?
Try GoCharting Premium
Unlock advanced orderflow, market profile, options desk, and real-time data — everything you just read about, live in your charts.