@dr_panther: the history doesn't have unwanted bars. It's the live data that have these additional wrong bars. That's because Zorro's quoting is running when the particular market is closed. And then it produces additional bars that are not in the history.

@boatman: when I put only the entry logic inside the if() statement I get no error that's right. But I can't skip these additional live bars. So, I tried to put the whole run() function inside an if statement to execute the system only during these times.

I am stuck, here. A function like StartWeek/EndWeek would be needed so that Zorro logs out at the end of the day and doesn't produce these surplus bars, something like StartDay/EndDay.

Doesn't anybody else have these live trading problem? It should occur with every non-24h market and on a lot of timeframes.

BTW: I tried it also with IB in demo-mode. It's the same behaviour.

Last edited by MattY; 11/14/16 20:45.