Create a strategy object that works similarly to our Interpreter. Ideally, this would inherit most methods from the Interpreter, so that we only need to make changes to the strategy in a single place. To inherit all necessary methods, it might be necessary to modify the Interpreter as well. Note that if we don't use inheritance, this would require us to change the trading strategy in two places for every single change, which is very prone to bugs and does not allow for testing these changes properly.
Create a strategy object that works similarly to our Interpreter. Ideally, this would inherit most methods from the Interpreter, so that we only need to make changes to the strategy in a single place. To inherit all necessary methods, it might be necessary to modify the Interpreter as well. Note that if we don't use inheritance, this would require us to change the trading strategy in two places for every single change, which is very prone to bugs and does not allow for testing these changes properly.
https://kernc.github.io/backtesting.py/doc/examples/Quick%20Start%20User%20Guide.html https://kernc.github.io/backtesting.py/