Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Occasionally when trade closes, stop limit order isn't cancelled

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Occasionally when trade closes, stop limit order isn't cancelled

    HI -

    I have a Strategy for the emini Russells (actually two - one for short trades and one for long) which involve three exit possibilities - a trailing stop, take profit, or a cross of a stochastic indicator. Occasionally when the exit is triggered with the stochastic indicator cross and a new trade in the opposite direction is triggered on the same bar the following issues occur - 1) Let's say that the old trade is a short position, so the new trade triggers a long order which exits the short position leaving a net zero trades active. 2) The trailing stop order of the first trade remains open while the system places two stop orders (the trailing stop and take profit orders), leaving three stop limit orders open.

    If there are any solutions to preventing this from happening that would be very helpful. I have been using the Strategy Wizard to "code" these strategies, and was wondering if using a stop limit order (one or two ticks above the market [longs] or one or two ticks below the market [shorts], that could prevent this from happening. If this is the case how do you instruct the system to place stop limit entry orders in the Strategy Wizard?

    Many thanks!

    #2
    Hello bonwitt,

    Thank you for writing in. Using two strategies to go opposite directions in the same market is going to cause problems like this as strategies do not communicate with one another.

    The simplest solution would be to combine your strategies into one so that it is the only thing manipulating the account position.

    In this scenario based on your example, the EnterLong() would successfully close the previous stop limit order, before the position reversed.

    Please let me know if you have any questions on doing this or if the issue persists afterwards.
    Michael M.NinjaTrader Quality Assurance

    Comment


      #3
      Many thanks!

      I try that out and let you know if it fixes the problem.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by kevinenergy, 02-17-2023, 12:42 PM
      117 responses
      2,766 views
      1 like
      Last Post jculp
      by jculp
       
      Started by Mongo, Today, 11:05 AM
      5 responses
      15 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by traderqz, Today, 12:06 AM
      8 responses
      16 views
      0 likes
      Last Post traderqz  
      Started by SightCareAubetter, Today, 12:50 PM
      0 responses
      2 views
      0 likes
      Last Post SightCareAubetter  
      Started by Skifree, Today, 03:41 AM
      5 responses
      14 views
      0 likes
      Last Post Skifree
      by Skifree
       
      Working...
      X