thanks
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Auto Trailing Stoploss
Collapse
X
-
Hello cbsplanet,
Thank you for your post.
As this appears to be in relation to creating an automated strategy with NinjaScript, I've moved your post to a more appropriate forum.
A basic trailing stop can be added to your strategy using SetTrailStop:
SetTrailStop will begin trailing at a price you specify and will trail in the direction of profit by 1 tick for each tick in profit reached.
If you're wanting a more complex trailing action in a strategy you would want to use Exit orders and create logic to move the exit in a trailing fashion. I've attached a simple Strategy Builder example that demonstrates - you can unlock the code to view the logic if you're manually coding in the NinjaScript Editor window. You can test this with the Sim101 account to get an idea of how that functions.
While ATM strategies may be submitted from an automated strategy, it's generally simpler to use SetStopLoss/SetProfitTarget/SetTrailStop at first - using an ATM within a strategy would require advanced NinjaScript skill and cannot be done in the Strategy Builder. Further information regarding the use of ATMs in a strategy may be found in our help guide here:
Please let us know if we may be of further assistance to you.Attached Files
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, Today, 05:17 AM
|
0 responses
52 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
130 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
70 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
43 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
48 views
0 likes
|
Last Post
|

Comment