Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Filling outside of bar price

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

    #16
    I tried now to debug it as good as possible, but still have no solution. I think, you will confirm that there are two conditions for the exit: first, there have to be a long position. And second, the low of the current 5 min bar has to be lower than the donchian channel. Now, the first condition is obviously filled since this is a long only strategy. The second point I checked with Print() commands and the result is obvious here too: the low of the bar was around one hour before the stop got triggered, so the position should have been closed one hour earlier.
    The problem is, that for example during other trades, where the exit condition triggered, there is no hint in the executions panel, WHEN the stop order got cancelled. This could perhaps be helpful.
    And again: I don't know what's wrong with this because when I take out the stop, everything works absoluetely fine.

    Regards,

    Sepp

    Comment


      #17
      This is normally a clue then that your Set() method is 'colliding' with the other order > internal order handling rules - have checked the TraceOrders output for this time range to make sure this is not the case?

      Comment


        #18
        So, if I understand correctly, there is no possibility to get this working right now? Would it be a possibility to use the 5 min bars not as a secondary time frame, but as a primary? Perhaps this would help.
        Would there also be any possibility to make an alternative to the stop loss? I thought of something like: if unrealized loss == 150 ticks -> ExitLong(). Would something like this work? And I understand correctly, that I can't have a stop loss running the same time as I'm using a ExitLong(Stop)Limit order?

        And for a feedback: this would be very good, if you would change this and allow two exit conditions at the same time, perhaps connected with an OCO order. I have no idea of programming, but I think this shouldn't be too complicated to implement in NT7.

        EDIT: for the TraceOrders: I've checked them and there was nothing unspecial. The exit condition order only gets generated when the condition is filled but in these two times there was no market order generated.


        Regards,

        Sepp
        Last edited by MasterSepp; 01-04-2010, 11:27 AM.

        Comment


          #19
          No, the added series has to smaller - this will change with NinjaTrader 7.

          Correct, you can't mix Exit()'s and Set()'s.

          For NinjaTrader 7 we'll provide two approaches then - the one we have right now and a new unmanaged one, which would offer more flexibility but of course you need manage everything yourself in the code.

          If you like, contact at the support adress with the script and include when exactly this occured (and exact chart setup needed) and I'll look here.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          567 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          330 views
          1 like
          Last Post Geovanny Suaza  
          Started by Mindset, 02-09-2026, 11:44 AM
          0 responses
          101 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by Geovanny Suaza, 02-02-2026, 12:30 PM
          0 responses
          548 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          548 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X