Price Versus Bollinger Bands
vs bollinger upper pct, price vs bollinger lower pct.">
What SteadyEdge calculates
This page documents the exact runtime calculation for the listed filter IDs. Formula symbols use O , H , L , C , and V for the current candle open, high, low, close, and volume; p is the configured lookback.
- Registry filter IDs: price_vs_bollinger_upper_pct , price_vs_bollinger_lower_pct
Exact formula
upper distance = 100*(C_t-upper_t)/upper_t
lower distance = 100*(C_t-lower_t)/lower_t
upper/lower use SMA(C,period) +/- std_dev*population_std(C,period)
Parameters, defaults, and bounds
- period : default 20 ; 2–100
- std_dev : default 2 ; 0.001–50
How the rule passes
above requires a strict > comparison.
below requires a strict < comparison.
cross_above requires the previous value below the threshold and the current value at or above it.
cross_below requires the previous value above the threshold and the current value at or below it.
Data, timing, and warm-up
Candle filters use the rule timeframe and the latest candle at or before the evaluation time. A non-finite calculated value does not pass.
Every rule in the same filter set must pass. Test Filters and a backtest validate the complete set.
Related articles
- Filters Reference
- How Entry Filters Work
- Timeframe, Operator, Value, And Params