1. Read a file containing all stock symbols that I wish to process ( yes I know I can read and parse a file with StreamReader )
2. For each stock symbol:
a. Add a PeriodType.Day Bars object
b. Run the symbol loaded in step a through the Ninja bars analysis so that the OnBarUpdate is called for the symbol loaded in step a.
c. Unload the stock loaded in step a in order to free memory for the next stock.
I can’t figure a way to do this. I think the key to get it to work is to have the code that reads the file and loads the Bars object to be outside of the OnBarUpdate() of the primary symbol for which the indicator was loaded to evaluate. The Initialize() method won’t do because there’s no way to continuously run the indicator from there.
The answer has to be that an indicator loads a Bars object and then somehow runs a secondary indicator, passing that DataSeries over to it for it to accept as the primary dataseries. Is this possible?
My goal is to analyze the entire stock universe in one batch run.
Comment