Strategy_perf[] execution time

Hi,
When does the strategy_perf= function suppose to stop executing? It kept running with below output:
Strategy’s past performance is good

Today’s trading signal is: Buy

Strategy’s past performance is good

Today’s trading signal is: Buy

Strategy’s past performance is good

Today’s trading signal is: Buy

Retraining the model

Not trading for today

Course Name: Decision Trees in Trading, Section No: 10, Unit No: 12, Unit type: Notebook

Hi,

So, strategy_perf is actually a list that stores the performance during the simulation. If you look at the code below (taken from the notebook), you will notice a for loop that runs simulation_length times. In this case, simulation_length is set to 252 in the notebook, so the loop will execute 252 times.

for i in range(simulation_length):

Thanks for the reply