Different Sharpe Ratios for MultipassBacktest and Quantiacs Mulipass Backtest


@magentakabuto Unfortunately, even the strategy that got rejected due to a negative sharpe ratio, has the same ones as in the screenshot for 3 passes

@magentakabuto Sry to post again. Now I changed to 20 passes and suddenly the sharpe ratio went up and this is the strategy that got rejected. I am totally confused!

@magentakabuto 50 passes.....

Hello
I see that you are using precheck, this is the fastest way to check the strategy
https://github.com/quantiacs/toolbox/blob/main/qnt/precheck.ipynbif the strategy statistics are different, your algorithm looks into the future.
does your algorithm calculate the weights to trade every day?
or do you calculate all the weights using all the data in one pass and then use them for a specific date? like cache

@vyacheslav_b hey thx for your reply. Yes the strategy Sharpe ratio differs from the multipass backtest.
But Quantiacs says that multiple pass Backtesting avoids looking into the future, so I am confused.
The algorithm identifies certain patterns and only if those occur over a period of time, does it generate signals.
So it does not calculate weights to trade everyday 
@magentakabuto something like this, if this puts a bit light

Compare the two versions of the code.
def regime_trade(series): return "" def strategy(data): result = regime_trade(data) return result backtest(strategy=strategy)
in the first case, the available data for a specific date are used.
def regime_trade(series): return "" result = regime_trade(data) def strategy(data): return result backtest(strategy=strategy)
in the second case, all data is used.
I see that you have a very large Sharpe ratio, I think that you are using something similar to the second option.

@vyacheslav_b Hello again, thank you very much. Yes you are right.
Regards
Furqan 
@vyacheslav_b thank you!