Contents

backtesting 0.6.5

0

Backtest trading strategies in Python

Backtest trading strategies in Python

Stars: 7937, Watchers: 7937, Forks: 1394, Open Issues: 68

The kernc/backtesting.py repo was created 7 years ago and the last code push was 1 months ago.
The project is extremely popular with a mindblowing 7937 github stars!

How to Install backtesting

You can install backtesting using pip

pip install backtesting

or add it to a project with poetry

poetry add backtesting

Package Details

Author
Zach Lûster
License
AGPL-3.0
Homepage
https://kernc.github.io/backtesting.py/
PyPi:
https://pypi.org/project/backtesting/
Documentation:
https://kernc.github.io/backtesting.py/doc/backtesting/
GitHub Repo:
https://github.com/kernc/backtesting.py

Classifiers

  • Office/Business/Financial/Investment
  • Scientific/Engineering/Visualization
No  backtesting  pypi packages just yet.

Errors

A list of common backtesting errors.

Code Examples

Here are some backtesting code examples and snippets.

GitHub Issues

The backtesting package has 68 open issues on GitHub

  • MultiBacktest.run errors out when tested strategy sometimes never enters a position
  • PERF: faster trade DataFrame construction with many indicators
  • Finalize Trades
  • Stop Loss value being (still sometimes) erased when reached
  • backtesting library skips bars where any indicator has NA values (or don't place orders)
  • Speed Enhancements
  • Crypto issue with fractional size
  • Create Naitik
  • Include the number of long and short trades in the output report
  • Introduce flexible height by proportially sizing elements
  • Add QTradeX to alternatives.md
  • Add shape and size for scatter plot
  • Friendly Note Regarding Your GitHub & backtesting Profile Picture
  • feat: added color bar for each heatmap
  • Iteration with Single-Step Progression to Improve Flexibility and Adaptability in Algorithmic Strategies

See more issues on GitHub

Related Packages & Articles

PyAlgoTrade 0.20

PyAlgoTrade is an event driven algorithmic trading Python library.

finta 1.3

Common financial technical indicators implemented in Pandas.

finplot code example

Here’s a code example using the finplot library in Python to create a simple financial plot

pandas-ta 0.4.71b0

A Comprehensive Python 3 Technical Analysis Library with Pandas Dataframe Extension for Quantitative Researchers, Traders, and Investors.