I am planning to write NinjaScript Strategy to be used for forex automated trading and have the following general questions that I am hoping someone can help with:-
(a) In order to setup and run a NinjaScript Strategy, do I need to subscribe and pay for a separate forex quote data vendor to feed the NinjaTrader? or will the NinjaTrader able to access realtime quotes directly from the broker (say, eg. forex.com)? If NinjaTrader is able to access and get realtime quotes from my broker without the need for a separate quote vendor connection, is there anyway whereby NinjaTrader can record the stream of realtime forex quotes for a particular pair and then build a historical database out of that?
(b) I am a beginner in terms of NinjaScript, and I note from the first tutorial - level 1 entitled "Using price variables" introduced the use of important variables such as Open[0] and Close[0], etc. My major question is how do we differentiate between the different timeframe data, eg. how do we make reference to Open price for a 1-minute interval or 5-minute or 1-day as they are all different? What happens if NinjaTrader is connected to the broker and tick data are coming in, is how are these tick quote accessed via the NinjaScript in the Strategy?
Thanks very much in advance.
Kanda
Comment