mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-25 22:08:05 +00:00
Merge branch 'dev'
This commit is contained in:
@@ -13,9 +13,7 @@
|
||||
| **PineScript** | [adxvma.pine](adxvma.pine) |
|
||||
|
||||
- ADXVMA is an adaptive IIR filter that uses the Average Directional Index (ADX) as its smoothing constant.
|
||||
- Parameterized by `period` (default 14).
|
||||
- Output range: Tracks input.
|
||||
- Requires `period * 2` bars of warmup before first valid output (IsHot = true).
|
||||
- **Similar:** [KAMA](../kama/kama.md), [VIDYA](../vidya/vidya.md) | **Complementary:** ADX for trend strength | **Trading note:** ADX-based Variable MA; adapts smoothing using ADX measurement.
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
ADXVMA is an adaptive IIR filter that uses the Average Directional Index (ADX) as its smoothing constant. When ADX is high (strong trend), the smoothing factor approaches 1.0 and the filter tracks price aggressively. When ADX is low (range-bound), the smoothing factor approaches 0.0 and the filter barely moves. This creates a moving average that automatically switches between responsive trend-following and noise-immune range-holding without external regime detection.
|
||||
@@ -147,4 +145,4 @@ O(1) per bar. State is 4 RMA scalars + OHLC history + VMA output. WarmupPeriod =
|
||||
| ADX computation | Partial | Vectorizable ratio except for recursive RMA |
|
||||
| Adaptive VMA | No | Recursive IIR (alpha depends on computed ADX) |
|
||||
|
||||
All four RMA passes and the adaptive VMA are recursive IIR — inherently sequential. Batch mode can vectorize TR and DM computation (pure per-bar arithmetic) then run scalar RMA sweeps. Net batch speedup for large series: ~1.5× (TR/DM vectorization only).
|
||||
All four RMA passes and the adaptive VMA are recursive IIR — inherently sequential. Batch mode can vectorize TR and DM computation (pure per-bar arithmetic) then run scalar RMA sweeps. Net batch speedup for large series: ~1.5× (TR/DM vectorization only).
|
||||
Reference in New Issue
Block a user