
In simple English
This tool tests stock options trading ideas using past market records. You write a small script to check how a strategy performed over the last few years. It calculates your potential wins, losses and risk numbers in seconds. You need some programming knowledge to install and run it. The project is free to use under an open source licence.
What it is
Optopsy is a Python library for options research, strategy backtesting and portfolio simulation. It includes thirty-eight built-in strategy templates, a trade simulator and risk metric calculations.
What it is good for
Quantitative traders and solo builders who want to test complex options strategies like iron condors or credit spreads against historical price data without building a testing engine from scratch.
- Thirty-eight built-in options strategies ready to test.
- Calculates standard risk metrics like Sharpe and Sortino ratios.
- Includes a command-line tool for downloading and caching historical market data.
- Requires Python programming skills to write and execute test scripts.
- Historical market data requires an external data provider key, such as EODHD.
- Licensed under AGPL-3.0 (GNU Affero General Public License v3.0), which requires you to release your source code if you host the software as a network service.
Writing custom Python scripts from scratch to simulate options trades
pandas
- mementum/backtrader24k stars
An alternative fork of the classic backtesting engine for Python trading systems.
- jesse-ai/jesse8.7k stars
A Python framework for writing crypto trading strategies, testing them against past prices, and running them live.
- hummingbot/hummingbot20k stars
A free framework for writing and running automated trading programs on cryptocurrency exchanges.
- lballabio/QuantLib7.7k stars
The long-established free library for pricing and risk-managing financial instruments.
pip install optopsy[data]