Thank you in advance
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Why the Stops are not being honored?
Collapse
X
-
Why the Stops are not being honored?
I'm running the strategy and setted a StopLoss of 10 ticks and also a stop when the price crosses below the SAR again, but is only being stopped when the price crosses the SAR and the Stop of 10 ticks don't, how can I fix that?
Thank you in advance1 PhotoTags: None
-
Hello jeremy83846,
This depends on the code logic in the strategy.
If you are submitting market orders when either exit condition is true, I would expect the logic and the market order to exit on either condition.
If you are attempting to use SetStopLoss, there will only be one stop loss per order / signal name.
If you are using Exit methods, its not advised to use multiple exit orders on the same entry. Instead, the first exit order should be cancelled before a different exit order is submitted. (This would prevent both orders from filling and reversing the position)
If you are using the unmanaged approach, the entries and multiple exits could be using OCO which should be fine.Chelsea B.NinjaTrader Customer Service
-
-
Hello jeremy83846,
It general it is not advised to use multiple exits for the same entry.
However, are you finding that the condition to exit is evaluating as true?
Use prints to ensure that condition set 2 is evaluating as true.
Below is a link to a forum post that demonstrates using prints to understand behavior.
If you print the time stamp in the action block of Set to, at what times do you see the prints appear?Chelsea B.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by andrewtrades, Today, 04:57 PM
|
1 response
8 views
0 likes
|
Last Post Today, 05:02 PM | ||
Started by chbruno, Today, 04:10 PM
|
0 responses
6 views
0 likes
|
Last Post
by chbruno
Today, 04:10 PM
|
||
Started by josh18955, 03-25-2023, 11:16 AM
|
6 responses
436 views
0 likes
|
Last Post
by Delerium
Today, 03:42 PM
|
||
Started by FAQtrader, Today, 03:35 PM
|
0 responses
7 views
0 likes
|
Last Post
by FAQtrader
Today, 03:35 PM
|
||
Started by rocketman7, Today, 09:41 AM
|
5 responses
19 views
0 likes
|
Last Post Today, 03:33 PM |
Comment