After every bar close, grab bar information (open, high, low, close, timestamp) and send to a local program (either C# or Python) which would then do filtering and calculations and if it fits the criteria within program, send back to Ninjatrader a possible order (i.e. go long or go short).
I've thought of a couple ways to work on this such as using the stream writer to write the OHLC values for each bar to a text file and then having my program read the text file and send a possible order, however that seems to be a bit cumbersome and I am running into crossroads as it seems that I have to invoke and use the NTdirect.dll. There doesn't seem to be much documentation and becomes difficult to manage everything through multiple "routes". I wanted to see if anyone had any thoughts on whether this could be achieved more elegantly (maybe through an indicator or strategy) as that may be the fastest and best solution but I'm not sure if an indicator or strategy can communicate with external program.
I'd appreciate any thoughts about this.
Thanks!
Comment