@hghhgghdf-dfdf Tanks for reply. I checked this out and from I saw it is not suited my requirements (or I missed something). But in that context I need to use backtrader.indicators (a.e. backtrader.indicators.LaguerreRSI) outside backtrader as usual indicators. Is it possible?
I have the same problem as reported in the initial post:
in my strategy, I call self.order_target_value(...), when debugging into that function I get to the framework call value = self.broker.getvalue(datas=[data]) , this call returns an invalid value(a very large value, close to the value of the entire portfolio), in my case, it should return 0 since the ticker does not exist in IB portfolio
Can you try and replicate this behavior and fix in case there is a bug?
It seems to me, that the --replay parameter really delivers what I need:
tick based during live streaming
after each candlestick timeframe, len(self.data0) increases by one and also the last call to next() for that block seems to comprise consistent values for OHLC for the whole candlestick.