Why is the indicator always executed before the Strategy?
I noticed that it appears that the indicator is calculated for the whole time-series before the code in the strategy starts.
I don't see the rationale behind this. At index n you already have n+k calculated. That would be impossible in real-time.
Are am I missing something about the purpose of the indicator?
run-out last edited by
What you observed is vectorized computing of indicators.
That's a feature to speed up the process. Disable it by adding a param
runonce=Falsein your cerebro.run() call.