feat(dynamics): add PlusDI, MinusDI, PlusDM, MinusDM indicators

Complete thin Dx-composition wrapper indicators with full test coverage:

- PlusDi/MinusDi: Directional Indicator wrappers (DiPlus/DiMinus from Dx)
- PlusDm/MinusDm: Directional Movement wrappers (DmPlus/DmMinus from Dx)
- Individual validation tests per indicator directory (TALib, Skender, bounds)
- Combined unit tests (DiDm.Tests.cs) and validation tests (DiDm.Validation.Tests.cs)
- Quantower wrappers + tests for all 4 indicators
- PineScript v6 implementations with compensated RMA
- Normalized .md documentation for all indicators and categories
- 182 tests passing, 0 failures
This commit is contained in:
Miha Kralj
2026-03-11 20:21:52 -07:00
parent 56b86bebfb
commit 33d20f2a18
437 changed files with 4589 additions and 2792 deletions
+2 -28
View File
@@ -1,5 +1,7 @@
# DSP: Ehlers Detrended Synthetic Price
> *Detrended synthetic price removes the trend to expose the oscillation underneath — the signal beneath the drift.*
| Property | Value |
| ---------------- | -------------------------------- |
| **Category** | Cycle |
@@ -66,34 +68,6 @@ $O(1)$ per bar with $O(1)$ memory. Two EMA state variables plus two bias correct
|-----------|-------------|---------|------------|
| `period` | Dominant cycle period | 40 | $\geq 4$ |
### Pseudo-code
```
function DSP(source, period):
pFast ← max(2, round(period / 4))
pSlow ← max(3, round(period / 2))
αFast ← 2 / (pFast + 1)
αSlow ← 2 / (pSlow + 1)
emaFastRaw ← 0
emaSlowRaw ← 0
decayFast ← 1.0 // (1 - αFast)^n
decaySlow ← 1.0 // (1 - αSlow)^n
for each price in source:
emaFastRaw ← FMA(αFast, price, (1 - αFast) * emaFastRaw)
emaSlowRaw ← FMA(αSlow, price, (1 - αSlow) * emaSlowRaw)
decayFast *= (1 - αFast)
decaySlow *= (1 - αSlow)
emaFast ← emaFastRaw / (1 - decayFast)
emaSlow ← emaSlowRaw / (1 - decaySlow)
dsp ← emaFast - emaSlow
emit dsp
```
### Output Interpretation
| Condition | Meaning |