Statistic functions
Standard Deviation
Rolling population standard deviation of closing prices with a configurable multiplier.
- Engine
- TA-Lib
- Function
STDDEV- Input series
- close
- Outputs
- 1
How it works
STDDEV calculates rolling population variance over the close series, takes its square root, and multiplies the result by nbdev; non-positive variance outputs zero.
Use case
Use Standard Deviation as a rolling dispersion and volatility feature or as an input to deviation-based bands and thresholds.
Parameters
| Parameter | Type | Default | Bounds or options | Description |
|---|---|---|---|---|
| Time Period | integer | 5 | 2…100000 | Number of closing-price observations in each standard-deviation window. |
| Deviation Multiplier | number | 1 | -3e+37…3e+37 | Multiplier applied to the calculated population standard deviation. |
Outputs
| Output | Type | Description |
|---|---|---|
| Standard Deviation | number | Scaled rolling population standard deviation for the bar. |
Reading the result
Rolling standard deviation describes dispersion of the input values inside the configured window. It remains in source-price units after applying the configured multiplier, so its magnitude grows with both variability and nominal price scale.
It measures dispersion around a local mean, not market direction and not necessarily the same concept as volatility calculated from returns.
Common mistakes
- Comparing price-level standard deviation across differently priced assets.
- Confusing dispersion of closes with standard deviation of returns.
- Interpreting a high value as bullish or bearish.
- Forgetting that a multiplier rescales the output without changing the underlying dispersion pattern.
DataCat workflow notes
For cross-symbol analysis, consider a documented downstream normalization such as division by a local price baseline. Keep the raw output available for audit and handle near-zero denominators explicitly.