Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Bars Ago
Collapse
X
-
Bars Ago
I am trying to create a strategy that when WilliamsR crosses above -20.5 and then if the following bar closes above the high of the bar that crossed -20.5 : I want to go long on the end of that bar. Using the strategy wizard, I created a strategy. I used "cross above" Williams R -20.5 and I input 1 bars ago. I then used Close (0 bar ago) > High (1 bar ago). However, the strategy is just going long on the first bar that closes above -20.5. It is not looking for my confirmation. I have played with the Bars Ago section on the Williams R and the Close/High pieces for hours now to no avail. Please Help. Thank you.Tags: None
-
Your code is working as expected. You are not evaluating the correct bar. Please take a look at your screenshot. The order was actually placed at the end of the big large green bar. Because your conditions were evaluated when that bar was closed your trade actually happens at the open of the next bar. That is what you are seeing and everything is working as expected.Josh P.NinjaTrader Customer Service
Comment
-
Not sure what you mean. You have one signal bar. From the signal bar you justify if you want to trade or not. If you say yes, then you place a trade. This trade cannot fill until the next available tradeable location. That location is the open of the next bar.Josh P.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
640 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
366 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
107 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
569 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
572 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment