Lab

Open implementations

Reference Python, Rust, and R code for Daru Finance’s public M-models and supporting analyses. These are the implementations behind articles published on this site — intentionally minimal, intentionally readable, intentionally reproducible.

λ₊
(a) eigenspectrum · MP null
M/01strategy-rmt

Eigenspectrum of the strategy correlation matrix

Marchenko–Pastur and parallel-analysis eigenspectrum of strategy correlation matrices. Reference implementation of the firm's M/01 model.

PythonRead method
View on GitHub
τ̂
W = |Z| − |Z̃| · FDR threshold τ
M/02hc-knockoffs

Sparse signal detection with FDR control

Higher Criticism plus Model-X knockoffs for FDR-controlled strategy selection. Reference implementation of the firm's M/02 model.

RRead method
View on GitHub
ε=0ε=1
H₀ persistence barcode
M/03strategy-tda

Persistence barcodes on strategy structure

H0 persistence barcode under correlation-distance Vietoris–Rips on strategy populations. Reference implementation of the firm's M/03 model.

PythonRead method
View on GitHub
u
POT-GPD tail · log P(X > x)
M/04tail-evt

Peaks-over-threshold and pairwise tail-coupling

Peaks-over-threshold GPD fits and pairwise tail-coupling χ on cross-asset returns. Reference implementation of the firm's M/04 model.

RustRead method
View on GitHub
OOSISsel. biasparam σskill ≈ 0
IS−OOS gap · variance decomposition
M/05strategy-overfitting

Decomposing the IS-OOS Sharpe gap

Variance decomposition of the in-sample / out-of-sample Sharpe gap into selection bias, parameter-choice noise, and residual skill across 10 deep-WFO crypto assets.

PythonRead method
View on GitHub
ATRMACD
smooth basin · spiky peak
M/09strategy-surface-stability

Does in-sample smoothness predict out-of-sample skill?

Pre-registered empirical test of whether in-sample Sharpe-surface smoothness under a fixed five-perturbation suite predicts out-of-sample skill across SOL / DOGE / BTC walk-forward partitions.

PythonRead method
View on GitHub
2-D embedding · robust islands vs fragile mass
M/06strategy-manifold

PCA + UMAP geometry of the strategy population

PCA + UMAP embedding of large strategy populations from a 90-feature metric vector, with connectivity-based separation of robust vs fragile strategies.

PythonRead method
View on GitHub
K=4 HMM regimes · posterior γ_t
M/07strategy-regime

Hidden-Markov regime segmentation

Gaussian HMM regime segmentation on (logret, volatility, trend) features with K selected by BIC; cross-asset 4-state preference across crypto majors.

PythonRead method
View on GitHub
σ_oos2549kLWHuber
OOS vol · universe-saturation curve
M/08strategy-robust-portfolio

Universe-saturation of minimum-variance portfolios

Universe-saturation analysis for minimum-variance portfolios drawn from large strategy pools, comparing Ledoit–Wolf shrinkage, Huber-style robust, and sample covariance estimators.

PythonRead method
View on GitHub
μ
population Sharpe density
strategy-stats

Sharpe density and (μ, σ, t) population scatter

Population-level Sharpe density and (mean, std, t) scatter over a strategy universe. Supporting library for empirical analyses.

PythonRead method
View on GitHub
9-asset universe
cross-asset correlation cube
strategy-corrcube

Cross-asset rolling correlation cube

Cross-asset sample correlation cube over a 9-asset universe. Supporting library for population-level analyses.

PythonRead method
View on GitHub
cluster structure · collective signal
signal-is-collective

The signal is collective

Reproducible synthetic demos behind the article 'The signal is collective'.

PythonRead method
View on GitHub

Frameworks (full backtester implementations) and the Monte-Carlo paper reproducibility package are intentionally excluded from this list — they live in their own dedicated places. See github.com/DaruFinance for the full repository index.