NinjaTrader_Josh
04-05-2008, 11:23 PM
Reference sample for NinjaTrader 6.5.XXXX.X or greater.
As of NinjaTrader 6.5, you can submit orders to different Bars objects. This allows you the flexibility of submitting orders to different timeframes. Like in live trading, taking entry conditions from a 5min chart means executing your order as soon as possible instead of waiting until the next 5min bar starts building. You can achieve this by submitting your orders to a more granular secondary bar series to achieve an "intrabar" fill.
The attached reference sample demonstrates the following concepts:
Finding entry conditions on the primary bar object
Submitting orders to the secondary bar object for an intrabar fill
Important methods and properties include:
Add() (http://www.ninjatrader.com/support/helpGuides/nt7/add3.htm)
BarsInProgress (http://www.ninjatrader.com/support/helpGuides/nt7/barsinprogress.htm)
EnterLong() (http://www.ninjatrader.com/support/helpGuides/nt7/enterlong.htm)
Other methods and properties of interest include:
BarsArray (http://www.ninjatrader.com/support/helpGuides/nt7/barsarray.htm)
EnterLongLimit() (http://www.ninjatrader.com/support/helpGuides/nt7/enterlonglimit.htm)
Import instructions for NinjaTrader 6.5.XXXX.X or greater:
Download the file contained in this thread to your PC desktop
From the Control Center window, select the menu File > Utilities > Import NinjaScript
Select the downloaded file
As of NinjaTrader 6.5, you can submit orders to different Bars objects. This allows you the flexibility of submitting orders to different timeframes. Like in live trading, taking entry conditions from a 5min chart means executing your order as soon as possible instead of waiting until the next 5min bar starts building. You can achieve this by submitting your orders to a more granular secondary bar series to achieve an "intrabar" fill.
The attached reference sample demonstrates the following concepts:
Finding entry conditions on the primary bar object
Submitting orders to the secondary bar object for an intrabar fill
Important methods and properties include:
Add() (http://www.ninjatrader.com/support/helpGuides/nt7/add3.htm)
BarsInProgress (http://www.ninjatrader.com/support/helpGuides/nt7/barsinprogress.htm)
EnterLong() (http://www.ninjatrader.com/support/helpGuides/nt7/enterlong.htm)
Other methods and properties of interest include:
BarsArray (http://www.ninjatrader.com/support/helpGuides/nt7/barsarray.htm)
EnterLongLimit() (http://www.ninjatrader.com/support/helpGuides/nt7/enterlonglimit.htm)
Import instructions for NinjaTrader 6.5.XXXX.X or greater:
Download the file contained in this thread to your PC desktop
From the Control Center window, select the menu File > Utilities > Import NinjaScript
Select the downloaded file