- When I got a signal to go long, I will submit order for long limit entry. Once the long limit entry is filled, I submitted a pair of profit taking and stop loss orders.
- I encountered an exception/error and my strategy was disabled. However my long position and pair of bracket orders are still alive.
- Price move to hit my stoploss and the position is closed.
- Price then move towards my profit taking and new short position is being initiated. (If my strategy is still alive, this profit taking order would have already being cancelled at step3)
- At the end of the day I ran into a big red P&L due to the unwanted position.
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
How to handle strategy crashes with pending orders?
Collapse
X
-
How to handle strategy crashes with pending orders?
Scenario I encountered during my forward testing:Last edited by elirion; 05-02-2024, 03:23 AM.Tags: None
-
Hi Brandon,
I am using Exit methods for my stoploss and profit target orders
The error i encountered is: https://forum.ninjatrader.com/forum/...ror-on-barsago
However I can never simulate the problem again with replay function.
The error message is not important, I want to cater to ALL sort of errors that can potentially CRASH my strategy and left my positions and orders hanging in the air.
I have done these steps, please comment if they are viable:
1) under tools: options: strategies:
2) at the code level
I am testing with positive result, I can fatten my positions and cancel all pending orders. I can only test by disabling the strategy manually. Do you have any suggestion for me to simulate a real crash within the strategy ?
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, Yesterday, 05:17 AM
|
0 responses
56 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
132 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
73 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
45 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
49 views
0 likes
|
Last Post
|


Comment