Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
How Do I enter a trade not on the close but LOW???
Collapse
X
-
-
-
The orders would be placed by default on the next bar, so you can just act on your doji entry condition and place a limit order at Low[0] (the last completed bar on CalculateOnBarClose) - http://www.ninjatrader.com/support/h...rlonglimit.htm
That order would stay for one bar only though, if you don't resubmit or set liveUntilCancelled to 'true'.BertrandNinjaTrader Customer Service
Comment
-
I got this so far Where would I put LiveUntilCancelled?
Code:/// <summary> /// This method is used to configure the strategy and is called once before any strategy method is called. /// </summary> protected override void Initialize() { CalculateOnBarClose = true; } /// <summary> /// Called on each bar update event (incoming tick) /// </summary> protected override void OnBarUpdate() { // Condition set 1 if (Open[0] == Close[0]) { EnterLongLimit(DefaultQuantity,Low[0], ""); } }
Comment
-
The liveUntilCancelled property would be set as part of the more advanced overload available for the EnterLongLimit() -
Code:EnterLongLimit(int barsInProgressIndex, [I]bool liveUntilCancelled[/I], int quantity, double limitPrice, string signalName)
BertrandNinjaTrader Customer Service
Comment
-
is this correctCode:protected override void OnBarUpdate() { // Condition set 1 if (Open[0] == Close[0]) { EnterLongLimit(0,true,DefaultQuantity, Low[0], ""); } }
Comment
-
Cool!!! Hey I have one more question to ask. how can I tell ninjatrader to exit the long position after 2 bars. I noticed that when I put profit target of 4 ticks, it thinks all of the candles are profitable....... or should I create a muti time frame that takes the long on the 1 min chart?? which one would work better
Comment
-
Correct, per default it could not look intrabar - that's something we have on our feedback list for the next major update though.
For now a MultiSeries script would be best, sending to 1 min for example for execution and then using the Exit methods for your stop / target, so you could have them deciphered as well on the lower series with added granularity.BertrandNinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by iceman2018, Today, 11:46 AM
|
1 response
6 views
0 likes
|
Last Post Today, 11:54 AM | ||
Started by Torontobluejays, Yesterday, 08:43 AM
|
4 responses
23 views
0 likes
|
Last Post Today, 11:50 AM | ||
Started by Ticks_66, Today, 09:50 AM
|
2 responses
14 views
0 likes
|
Last Post
by Ticks_66
Today, 11:50 AM
|
||
Decrease the size of the RegionHIghLightY on each tick when the price touches it
by cmtjoancolmenero
Started by cmtjoancolmenero, 04-29-2024, 03:40 PM
|
7 responses
27 views
0 likes
|
Last Post Today, 11:47 AM | ||
Started by akuntysh, 05-18-2018, 03:39 AM
|
11 responses
810 views
0 likes
|
Last Post Today, 11:39 AM |
Comment