Quantitative statistical methods: ADF unit-root / cointegration tests, GARCH volatility modeling, regression diagnostics (heteroskedasticity / autocorrelatio…
npx clawhub@latest install quant-statisticsQuant Statistics provides the core statistical toolkit used in quantitative investing and factor research. It covers time-series stationarity and cointegration testing, GARCH volatility modeling, regression diagnostics, nonparametric bootstrap inference, and hypothesis testing with multiple-testing correction. Install it to bring rigorous statistical foundations to strategy development, pair trading, and factor validation workflows.
npx clawhub@latest install quant-statisticsClick the Install button at the top of this page for one-click setup
Runs the Augmented Dickey-Fuller test on any time series and returns the test statistic, p-value, lags used, and 1%/5%/10% critical values. Clear decision rules map p-value ranges to actionable conclusions — use directly, difference the series, or apply cointegration methods.
Tests whether two non-stationary series share a long-run equilibrium, computes the OLS hedge ratio, constructs the spread, and estimates the mean-reversion half-life. Z-score thresholds for entry and exit signals are built into the output, providing the statistical foundation for pairs trading.
Fits a GARCH(1,1) model via the arch library and returns ω, α, β, persistence, long-run volatility, current conditional volatility, and a 5-day-ahead volatility forecast with AIC/BIC. Guidance on EGARCH and GJR-GARCH variants covers asymmetric leverage effects common in equity and crypto markets.
Runs White and Breusch-Pagan heteroskedasticity tests, Durbin-Watson and Ljung-Box autocorrelation tests, and VIF multicollinearity checks in a single workflow. Each test returns an interpretation and a concrete fix recommendation (e.g., HAC/Newey-West standard errors or WLS).
Estimates confidence intervals for any statistic — Sharpe ratio, alpha, maximum drawdown distribution — via resampling without distributional assumptions. A dedicated bootstrap_sharpe function flags whether the 95% CI excludes zero, giving a robust significance check for strategy performance.
Provides a quick-reference table of tests matched to common quant questions, and applies Benjamini-Hochberg FDR correction via statsmodels.stats.multitest when evaluating many factors or strategies simultaneously. Built-in rules of thumb link Sharpe magnitude and backtest length to statistical significance thresholds.
Test two equity or ETF price series for cointegration, estimate the hedge ratio and spread half-life, and generate z-score entry/exit signals. Ongoing cointegration monitoring is supported to detect relationship breakdowns.
Apply stationarity tests to raw factor series, diagnose factor-return regressions for heteroskedasticity and autocorrelation, and use bootstrap Sharpe confidence intervals with FDR correction to distinguish genuine factor premia from statistical noise across a large factor universe.
Fit GARCH(1,1) or asymmetric variants to return series to obtain conditional volatility estimates and short-horizon forecasts. Output parameters and long-run volatility levels feed directly into position sizing or option pricing workflows.
Run the full regression diagnostics checklist — linearity, normality, heteroskedasticity, autocorrelation, multicollinearity, and outliers — before interpreting any OLS-based factor model, ensuring standard errors and t-statistics are reliable.
statsmodels, arch, numpy, pandas must be available in the execution environment.arch library: required specifically for GARCH modeling (pip install arch).npx clawhub@latest install quant-statisticsLog in to write a review
No reviews yet. Be the first to share your experience!