[BUG] Synchronise backtest with real data

If I check the backtest on my already running strategies, I noticed that “real” positions are always 1 bar behind. That is, on 15m frequency strategy the backtest shows a position was opened 17:00, but “for real” it opened 17:15. I don’t think it is related to the strategy start time as I tried to “adjust” the backtest to shift its operation for 1 bar to no avail.

Moreover, I see both backtest and real positions closing at the same time (due to TP for example), but still the next real position opens exactly 1 bar later than the backtest one. Because of this some “real” positions are actually turning bad, because they entered too late in a volatile market.

Can you, please, make the backtest more accurate by ensuring it is in sync with real strategy historical trading data?


this discovery is very important. i hope pq team will come up with a good solution!

1 Like

Hi @ignat I raised this problem before and their response was that it is a visualisation problem that the backtest displays the open time when all trades occur at close see post below. Problem - entry/exit timing fault


I see now - this is a duplicate then, but I disagree as well that this is only a visualisation bug.

1 Like