Set up a Python backtesting environment with virtualenv, OS-aware dependencies, and folder structure.

skills.sh installs
2.1K
GitHub stars
229
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers OS detection, a virtual environment, optional TA-Lib system setup, package installation, and .env configuration
  • Installs openalgo, vectorbt, plotly, duckdb, openstatz, ccxt, and yfinance, and creates a top-level backtesting/ folder
  • Writes API keys for Indian, DuckDB, and crypto markets into a single root .env, added to .gitignore
  • Designed for Python users starting a VectorBT and OpenAlgo backtesting project on macOS, Linux, or Windows

Install

$ npx -y skills add marketcalls/vectorbt-backtesting-skills --skill setup -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Set up the complete Python backtesting environment for VectorBT + OpenAlgo.

Arguments

  • $0 = Python version (optional, default: python3). Examples: python3.12, python3.13

Steps

Step 1: Detect Operating System

Run the following to detect the OS:

uname -s 2>/dev/null || echo "Windows"

Map the result:

  • Darwin = macOS
  • Linux = Linux
  • MINGW* or CYGWIN* or Windows = Windows

Print the detected OS to the user.

Step 2: Create Virtual Environment

Create a Python virtual environment in the current working directory:

macOS / Linux:

python3 -m venv venv
source venv/bin/activate
pip install --upgrade pip

Windows:

python -m venv venv
venv\Scripts\activate
pip install --upgrade pip

If the user specified a Python version argument, use that instead of python3:

$PYTHON_VERSION -m venv venv

Step 3: TA-Lib System Dependency (Optional)

OpenAlgo ta (from openalgo import ta) is the default indicator library for this project - it ships 100+ indicators and needs no separate system dependency. TA-Lib is only needed if the user wants to be able to say "use talib" for a specific backtest.

Details

Repository
github.com/marketcalls/vectorbt-backtesting-skills
Categories
Finance & Trading, Python
First seen
May 16, 2026

More from marketcalls/vectorbt-backtesting-skills

All 6

Similar to Setup

More Finance & Trading