// the find
quantopian/pyfolio
Portfolio and risk analytics in Python
pyfolio generates performance tear sheets for trading strategies — Sharpe, drawdown, rolling beta, round-trip analysis, the works. It was built by Quantopian and pairs naturally with Zipline. Quantopian shut down in 2020, so this is effectively abandonware maintained by inertia.
The tear sheet output is genuinely thorough — drawdown periods, rolling Sharpe, vol decomposition, and position concentration in one call. Round-trip trade analysis in round_trips.py is a feature most competing libraries skip entirely. The interesting_periods.py file ships with pre-labelled market events (Lehman, COVID, etc.) so you can instantly see how your strategy behaved during known crises. Test coverage is real — CSV fixtures, not mocked DataFrames.
Quantopian is dead and the last meaningful commit is from 2023; nobody is merging PRs or fixing the pandas compatibility breaks that accumulate with every pandas minor release. The Zipline coupling is baked into the API surface — if you're not using Zipline, you're writing adapter glue before you get anything useful. No async support anywhere, so tearing a large portfolio blocks the process. The bayesian.ipynb example depends on PyMC3, which itself has been superseded twice since this was written.