ranaroussi/quantstats ? reverse-engineered prompt

Reverse engineered prompt

Build me a Python library for portfolio and strategy analysis that takes a series of returns and gives me the usual performance and risk metrics in a simple way. I want it to calculate things like Sharpe, Sortino, drawdowns, win rate, volatility, VaR, CVaR, and other common quant stats, and I want to be able to call them directly on a pandas Series if possible.

It should also make charts for performance, drawdowns, rolling stats, monthly and yearly returns, and an overview snapshot. I’d like a report feature that can generate a clean HTML tear sheet with metrics and plots, plus support for Monte Carlo risk simulations. If it can download sample stock returns for a ticker and work nicely with pandas, that would be great.

Make it easy to install and use, include clear docs or examples, and if you need to check anything current online, go ahead and look it up.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab