backtesting-frameworks

Develop backtests for trading strategies with bias and cost controls.

Updated Feb 26, 2026
One-click install
npx skills add https://github.com/AndyAnh174/wellness --skill backtesting-frameworks-andyanh174
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: backtesting-frameworks
Source: https://github.com/AndyAnh174/wellness/tree/main/.agent/skills/backtesting-frameworks
Command: npx skills add https://github.com/AndyAnh174/wellness --skill backtesting-frameworks-andyanh174

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Build robust backtesting systems that avoid common pitfalls like look-ahead bias, survivorship bias, and underestimating costs, enabling reliable strategy evaluation.

Core Features & Use Cases

  • Backtest architectures: event-driven, vectorized, and walk-forward frameworks to compare performance and guard against bias.
  • Realistic cost modeling and transaction costs to produce credible results.
  • Walk-forward analysis and Monte Carlo tests to assess robustness and generalization across different market regimes.

Quick Start

Run a backtest on your OHLCV data using the provided patterns to evaluate strategy performance.

Frequently Asked Questions about backtesting-frameworks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I avoid look-ahead bias and survivorship bias when building a trading strategy backtest?

To avoid look-ahead bias and survivorship bias in a backtest, you must use point-in-time data and safe testing frameworks. This approach ensures your strategy evaluation remains reliable by preventing future information from leaking into historical calculations.

What is the best way to structure an event-driven or vectorized backtesting framework?

The best way to structure a backtesting framework is to compare event-driven and vectorized architectures. This approach guards against common biases and supports reproducible strategy evaluation by processing market data sequentially or in batch arrays.

How do I run walk-forward analysis and Monte Carlo tests on my trading strategies?

You run walk-forward analysis and Monte Carlo tests by applying optimization patterns to your backtesting infrastructure. These tests assess strategy robustness and generalization across different market regimes by validating performance on rolling data windows and randomized sequences.

Can I use OHLCV data to evaluate algorithmic trading strategies with realistic transaction costs?

Yes, you can use OHLCV data to evaluate algorithmic trading strategies. The framework applies realistic cost modeling and transaction costs to your backtest, producing credible performance results that account for slippage and fees.

Why does my backtesting performance metrics show inflated returns during strategy validation?

Inflated backtesting performance metrics usually result from transaction-cost bias or look-ahead bias. You can correct this by implementing realistic cost modeling and using point-in-time data to ensure your strategy validation reflects actual market conditions.

When should I use walk-forward optimization instead of standard historical backtesting?

You should use walk-forward optimization instead of standard backtesting when you need to verify strategy stability across changing market regimes. This method assesses robustness by continuously re-optimizing parameters on rolling data windows to prevent overfitting.