I'd like to confirm the expected behavior of private DataSeries or public variables with the same name.
Background to my question is the following: I've developped several strategies (some of which I want to convert to indicators, and possibly run at the same time) which identical routines.
A. Public Data(or Bool, or Int) Series - For example, an IntSeries storing a condition like "# bars since signal was given", which itself calls a "SignalSeries". Both have the same name across all strategies, but are private.
B. Public variables: in a few instances, I may have given the same name to public variables - example, two strategies could have a public double "MACDMin" (but, depending on the strategy, not the same value!). Evidently, all have common variable names for offsets like entry price, stop, target...
1. What happenswhen running the strategies concurrently on the strategy tab on the same instrument, same timeframe - is there a chance strategy A could (erroneously for my purposes) access for example the DataSeries "number of bars since a signal was given" for strategy B?
2. Same question for public doubles
3. Is the behavior to be expected/answer to 1 & 2 different if running strategies from a chart?
4. Finally, if I convert these into indicators, and run concurrently the indicator and corresponding strategy from the same chart, could one mistakenly read info from the other? (this last question should be less of a problem since the values would in theory be identical, but there may be cases I haven't thought of where this could be a problem).
I looked through the forum could not find a thread explicity answering these exact questions. My understanding is that it is all contained within the strategy/indicator, and there is no way one can access data from another, even with the same name, unless explicitly referenced, but I would like to confirm.
Also, does this "same naming" consume more resources for NT? Would unique names (say: MACDMinA in strategy A, MACDMinB in strategy B etc.) be more efficient?
Thank you in advance!

Comment