Individual skill
backtrader
Event-driven backtesting with bar-by-bar execution, complex order types, multiple analyzers, and custom indicators
skills/backtrader/SKILL.md
Source commit 981e1d736cdc02bdc1c55c74ec9224e956414706
What was checked
- Matches the observed repository HEAD
- Yes
- Scanner rules are current
- No
- Repository scan complete
- No
- Skill scan complete
- No
- Observed behavior
- Not checked yet
- Last checked
- Nov 10, 2026
These are observations at the recorded commit, not a guarantee of safety. Review the source before running it.
Install this skill
Choose an agent in your Stack or copy a command below. Commands fetch the pinned commit and copy only this skill directory. Existing destinations are refused. Copying a command does not install anything.
An install command is unavailable: current rules, complete repository and skill scans, an eligible behavior level and a permitted license are required.
Repository context
- Repository stars (not skill ratings)
- 527
- Repository last updated
- Sep 3, 2026
- License
- MIT
Observed agent integration: No specific integration evidence. Standard SKILL.md installation does not imply verified compatibility.
- engineering Derived category
Files and excerpt
File metadata and permitted, redacted excerpts come from the recorded scan. Source links are pinned to that commit.
Browse files
SKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesSKILL.mdcore · 9,792 bytesreferences/api_guide.mddoc · 7,843 bytesreferences/strategy_patterns.mddoc · 8,188 bytesscripts/backtest_strategy.pyruns · 14,870 bytesscripts/bracket_orders.pyruns · 16,198 bytes
Read excerpt
# Backtrader
Backtrader is a Python event-driven backtesting framework that processes data bar-by-bar, simulating realistic execution with a built-in broker, order management, and position tracking. Unlike vectorized frameworks (vectorbt, pandas), backtrader walks through history one bar at a time, firing callbacks that let you implement complex order logic that depends on previous fills, partial executions, and conditional brackets.
## Event-Driven vs Vectorized
| Aspect | Backtrader (event-driven) | vectorbt (vectorized) |
|---|---|---|
| Execution model | Bar-by-bar callbacks | Whole-array operations |
| Speed | Slower (Python loop) | Fast (NumPy/Numba) |
| Order types | Market, limit, stop, stop-limit, bracket, OCO | Market only (native) |
| Realism | Built-in broker with commission, slippage, margin | Manual slippage modeling |
| Multi-timeframe | Native resampledata | Manual alignment |
| Best for | Complex strategies, bracket orders, portfolio | Fast parameter sweeps, simple signals |