Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Single trade in one direction
Collapse
X
-
Single trade in one direction
Hello: The below attached strategy places the order when bar changes color and on close of the bar. Is it possible in Strategy builder to place only one order, 1st order on change of candle color till next color change. Currently, it keeps placing orders based on current color till next color change. Please see attached picture of the chart . Thanks,Tags: None
-
Hello mtamaku,
Thanks for your post.
Please note that we have moved your thread to the Ninjatrader 8 Strategy Development forum as that is a more appropriate forum for this topic.
Yes, you can create a "flip-flop" type condition where you would place one trade, flip the state of a bool and then place a trade in the opposite direction (in conjunction with your conditions) and continue the flip-flop process. I've created and attached an example strategy builder strategy you can download, install, and test. It places no trades and colors the background when the conditions change. The conditions in this example are of an EMA crossing above or below an SMA.
ExampleFlipFlop.zip
To Import
Download the zip file to your desktop, keep them in the compressed .zip file.
From the Control Center window select the menu File> Utilities> Import NinjaScript
Select the downloaded .zip file
NinjaTrader will then confirm if the import has been successful.
Critical - Specifically for some NinjaScripts, it will prompt that you are running newer versions of @SMA, @EMA, etc. and ask if you want to replace, press 'No'
- Likes 1
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
89 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
135 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
68 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|
||
|
Started by cmoran13, 04-16-2026, 01:02 PM
|
0 responses
119 views
0 likes
|
Last Post
by cmoran13
04-16-2026, 01:02 PM
|
||
|
Started by PaulMohn, 04-10-2026, 11:11 AM
|
0 responses
69 views
0 likes
|
Last Post
by PaulMohn
04-10-2026, 11:11 AM
|

Comment