validation and profiles

This commit is contained in:
Miha Kralj
2026-02-26 22:02:52 -08:00
parent 9ab37c1200
commit 8a1ba95173
317 changed files with 18704 additions and 622 deletions
+35 -1
View File
@@ -1,4 +1,4 @@
# DECO: Ehlers Decycler Oscillator
# DECO: Ehlers Decycler Oscillator
## Overview
@@ -80,6 +80,40 @@ The indicator requires `longPeriod` bars before producing reliable output. The f
- **Roofing Filter:** HP + SSF combination for cycle isolation
- **BandPass Filter:** Ehlers' direct bandpass approach
## Performance Profile
### Operation Count (Streaming Mode)
DECO (Detrended Correlation Oscillator) subtracts a linear regression from price then computes correlation.
| Operation | Count | Cost (cycles) | Subtotal |
| :--- | :---: | :---: | :---: |
| Linear regression (O(N) or O(1) with prefix sums) | ~4 | 1 | 4 |
| SUB (detrend: price regression) | 1 | 1 | 1 |
| Correlation pipeline (see CTI) | ~22 | 7 | 156 |
| **Total** | **~27** | — | **~161 cycles** |
Dominated by the correlation computation. ~161 cycles per bar.
### Batch Mode (SIMD Analysis)
| Operation | Vectorizable? | Notes |
| :--- | :---: | :--- |
| Linear regression | Yes | Prefix-sum dot products; VFMADD |
| Detrend subtraction | Yes | VSUBPD |
| Correlation | Yes | See CTI batch analysis |
Fully vectorizable in batch. Regression and correlation both benefit from AVX2 VFMADD chains.
### Quality Metrics
| Metric | Score | Notes |
| :--- | :---: | :--- |
| **Accuracy** | 9/10 | Exact linear detrend + Pearson r |
| **Timeliness** | 5/10 | Two N-bar windows compound lag |
| **Smoothness** | 8/10 | Detrending removes linear drift; correlation bounded |
| **Noise Rejection** | 8/10 | Linear detrend + correlation is doubly robust to trend contamination |
## References
1. Ehlers, J. F. (2015). "Decyclers." *Technical Analysis of Stocks & Commodities*, September 2015.