May I ask what is the platform are you working on? QuantRocket?
Posts made by lssilva
RE: What is the direction of Backtrader
I can confirm that backtrader is by far the best option compared to zipline, and quantconnect. The zipline code is a mess, they implemented it, then decided to create a new library to implement basic statistics which they got wrong then created a new library to implement the risk metrics. It is inefficient and Quantopian holds back enough code to just make zipline unusable.
Quantconnect has a better architecture but it also has a lot of old legacy code.
Sharpe Ratio BT vs Pyfolio different values
I have a very simple strategy and in the end I run:
cerebro.addanalyzer(bt.analyzers.SharpeRatio) cerebro.addanalyzer(bt.analyzers.Returns) cerebro.addanalyzer(bt.analyzers.PyFolio)
Then I compare the return and Sharpe from bt to Pyfolio and they are
Sharpe Ratio 1.22111855094Total return 0.671019659277
Entire data start date: 2012-09-24 Entire data end date: 2017-09-22 Backtest months: 59 BacktestAnnual return 14.4% Cumulative returns 95.6% Annual volatility 15.2% Sharpe ratio 0.96 Calmar ratio 0.86 Stability 0.90 Max drawdown -16.8% Omega ratio 1.18 Sortino ratio 1.48 Skew 0.86 Kurtosis 8.21 Tail ratio 1.02 Daily value at risk -1.9% Gross leverage 0.60 Daily turnover 0.2% Alpha 0.04 Beta 0.81
Is it due to the Risk Free rate? Comission? Slippage?