$npx skillfedfor your agent

mean-reversion

Mean-reversion identifies when prices, spreads, or other financial metrics deviate from their long-run average and predictably return. This skill provides statistical tests (ADF, Hurst exponent, variance ratio) to confirm mean reversion, half-life estimation to time entries and exits, z-score frameworks for signal generation, and Ornstein-Uhlenbeck process modeling for continuous-time analysis.

Mean-reversion uses ADF testing, Hurst exponent, and z-score signals to identify and trade price reversions to equilibrium.

AI-generated summary based on this skill's SKILL.md

248 52 MITupdated by agiprolabs

Decision gist · record as of 2026-06-24

Mean-reversion uses ADF testing, Hurst exponent, and z-score signals to identify and trade price reversions to equilibrium. Mean-reversion identifies when prices, spreads, or other financial metrics deviate from their long-run average and predictably return. This skill provides statistical tests (ADF, Hurst exponent, variance ratio) to confirm mean reversion, half-life estimation to time entries and exits, z-score frameworks for signal generation, and Ornstein-Uhlenbeck process modeling for continuous-time analysis.

manual: git clone https://github.com/agiprolabs/claude-trading-skills → cp -r claude-trading-skills/skills/mean-reversion ~/.claude/skills/mean-reversion
skills/mean-reversion/SKILL.md · version d9c697ce

Use it when

  • Mean-reversion generates buy/sell signals by measuring z-score deviations from the mean.
  • Mean-reversion estimates mean-reversion speed and half-life—the time for a price to revert halfway to its mean.

Verify before relying

Read SKILL.md below before installing (5 files). Open directory: indexed for reading, not audited.

Same gist for agents: .md · .json

Install

agiprolabs/claude-trading-skills/mean-reversion · repository language: Python

Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

How does mean-reversion detect mean reverting assets?

Mean-reversion uses statistical tests including the Augmented Dickey-Fuller (ADF) test for stationarity, Hurst exponent calculation to measure mean-reversion strength, and variance ratio tests to confirm price series predictably return to their long-run average. These tests identify assets suitable for mean-reversion trading strategies.

What are z-score mean reversion signals and how do I use them?

Mean-reversion generates buy/sell signals by measuring z-score deviations from the mean. When a price deviates significantly (high z-score), mean-reversion signals a potential reversal trade. The skill calculates z-score thresholds to define entry and exit points, helping traders capitalize on temporary price dislocations.

How does mean-reversion estimate half-life for position sizing?

Mean-reversion estimates mean-reversion speed and half-life—the time for a price to revert halfway to its mean. This metric informs position sizing and holding periods. Faster half-lives suit shorter-term trades; slower ones require longer holding periods and larger position adjustments.

Can mean-reversion find cointegrated pairs for spread trading?

Yes. Mean-reversion identifies cointegrated pairs whose spreads exhibit mean-reverting behavior, enabling pairs trading strategies. The skill tests spread stationarity and models the relationship, allowing traders to profit from temporary divergences between correlated assets.

What is the Ornstein-Uhlenbeck process in mean-reversion modeling?

Mean-reversion models mean-reverting dynamics using the Ornstein-Uhlenbeck process, a continuous-time framework capturing mean-reversion speed and volatility. This approach enables more sophisticated parameter estimation and risk modeling compared to discrete-time methods.

How can mean-reversion be used for ranging market strategy?

Mean-reversion excels in ranging markets where prices oscillate around a stable mean. The skill identifies these conditions via statistical tests, then generates signals when prices deviate from the range. This approach works well for stablecoin depegs, funding rate arbitrage, and other mean-reverting dynamics in crypto and traditional markets.

SKILL.md

Rendered from the published skill. Quoted content, verbatim.

Mean Reversion

Mean reversion is the statistical tendency for prices, spreads, or other financial variables to return toward a long-run average after deviating from it. A mean-reverting series overshoots its mean, then corrects back -- creating predictable oscillations that can be traded.

When Mean Reversion Works

  • Ranging markets: Sideways price action with clear support/resistance
  • Pairs spreads: Spread between cointegrated assets reverts to equilibrium
  • Oversold/overbought extremes: RSI, Bollinger Band, or z-score extremes in stationary series
  • Funding rate arbitrage: Perpetual funding rates revert to baseline
  • Stablecoin depegs: Classic mean-reversion opportunity (peg = known mean)
  • Post-dump recovery: Brief mean-reversion windows after initial PumpFun dumps

When Mean Reversion Fails

  • Strong trending markets (most crypto most of the time)
  • Regime changes: what was stationary becomes non-stationary
  • Structural breaks: token migration, protocol upgrade,

(truncated - see the full file via the links below)

File tree — 5 files
skills/mean-reversion/SKILL.md
skills/mean-reversion/references/statistical_tests.md
skills/mean-reversion/references/strategy_design.md
skills/mean-reversion/scripts/mean_reversion_test.py
skills/mean-reversion/scripts/pairs_scanner.py

Let your AI agent find skills like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.

wish › “Identify and test mean-reverting price series using statistical tests”

Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →

Related skills

cointegration-analysis
by agiprolabs · agiprolabs/claude-trading-skills

Cointegration Analysis identifies when two non-stationary price series move together toward a stable equilibrium, enabling statistical arbitrage and mean-reversion trading. The skill implements Engle-Granger two-step regression, Johansen multivariate testing, and rolling window monitoring to detect relationship breakdowns. Use it to screen correlated assets, estimate hedge ratios, and validate spread mean reversion before deploying pairs strategies.

MITupdated Jun 2026
★ 248repo stars
feature-engineering
by agiprolabs · agiprolabs/claude-trading-skills

Transform raw market data into stationary, predictive features for crypto trading models. This skill covers price, volume, technical, microstructure, and on-chain feature construction with emphasis on avoiding lookahead bias and ensuring stationarity. Feature quality matters more than model complexity in trading ML.

MITupdated Jun 2026
★ 248repo stars
regime-detection
by agiprolabs · agiprolabs/claude-trading-skills

Regime Detection classifies market conditions across volatility and trend axes to help you choose the right strategy for current conditions. It combines simple approaches like ATR percentiles and ADX with statistical methods including Hurst exponent and change-point detection, with tuning for crypto's faster regime shifts.

MITupdated Jun 2026
★ 248repo stars
pair-trade-screener
by tradermonty · tradermonty/claude-trading-skills

Pair Trade Screener detects statistical arbitrage opportunities by identifying cointegrated stock pairs within sectors and analyzing their spread behavior. The skill uses correlation analysis, cointegration testing, and z-score calculations to generate market-neutral trading signals based on mean-reversion patterns. Designed for investors seeking uncorrelated trading strategies that profit regardless of overall market direction.

MITupdated Jul 2026
★ 2,514repo stars
correlation-analysis
by HKUDS · HKUDS/Vibe-Trading

Correlation-Analysis discovers asset pairs with strong co-movement for pairs trading and hedging through multiple analytical modes: co-movement scanning, deep return correlation studies, sector clustering, and cointegration testing. It computes Pearson, Spearman, and Kendall correlations, rolling dynamics, and spread Z-scores to identify statistically significant relationships.

MITupdated Jul 2026
★ 28,096repo stars
quant-statistics
by HKUDS · HKUDS/Vibe-Trading

Quant-statistics provides time-series testing and volatility modeling tools for quantitative investing. It covers stationarity detection via ADF tests, cointegration analysis for pair trading, GARCH volatility forecasting, and regression diagnostics including heteroskedasticity and autocorrelation checks.

MITupdated Jul 2026
★ 28,096repo stars

More skills bet-sizing (MIT) · volatility-modeling (MIT) · garch-volatility-toolkit (MIT) · volatility-modeling (MIT)

Tags
statistical-testingspread-tradingsignal-generationreversion-metricspairs-analysisregime-filteringstationarity-checktime-series-modelingrisk-adjusted-sizing