I have a custom strategy that I am building. Let's say it's called strategyMain.
I'd like to be able to create another strategy that basically inherits all the properties, variables, and functions of strategyMain. Let's call this second strategy, strategyMainCloned.
I would use these 2 strategies on 2 separate instruments/charts (say ES and CL)... but I want these 2 separate instance so that I can track the PNL and backtest and forward test them separately without the PNL for strategyMain being aggregated between instrument 1 and instrument 2.
I know I can duplicate/clone the strategy and have a full copy of all the source code from strategyMain. But I'd rather have one main source of the code, so that as I need to tweak it, I only need to update the code in one place. Ideally, strategyMainCloned would automatically inherit the updates that I make to strategyMain.
How would I do that within Ninjascript (Editor)?
Thanks.

Comment