Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

misplaced orders

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

    misplaced orders

    Hello,

    Attached is an example of a minimal strategy that buys and sells at specific bar numbers.
    I ran it in Playback mode.
    While the Print statements in OnOrderUpdate & OnBarUpdate indicate the orders are placed and filled where intended, the actual orders on the chart are totally misplaced.
    What is the explanation for this? Is it because of a setting in ControlCenter > Tools > Options maybe?

    Thank you for your help.
    Attached Files

    #2
    Hello utilizator,

    Can this only be reproduced in real-time and not historically?

    I am not able to reproduce this behavior.

    Below is a link to a video of the test.
    https://drive.google.com/file/d/1GtJ...w?usp=drivesdk

    The prints show the time most recent fully closed bar.

    (If you want the execution fill time, print this from OnExecution())
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea B.,

      Thank you for your reply.

      I can see that you actually reproduced the issue I was referring to (attached screenshot from the movie):
      * Print() says that BUY is filled at bar# 96375 and SELL is filled 20 bars later, at bar# 96395
      * on chart though we see BUY and SELL on the same bar, not spaced 20 bars one from another ...

      Shouldn't we see on chart a BUY at bar# 96375 followed by a SELL 20 bars later?

      Note: on the movie, what is bar# on chart where the BUY & SELL are drawn? 96375 or 96395? My guess is that neither of the two ...

      Thank you.
      Attached Files
      Last edited by utilizator; 08-03-2020, 10:57 AM.

      Comment


        #4
        Hello utilizator,

        It takes time for an order to go through order states and fill, this means that the fill can be several ticks after the entry was submitted. This can change the amount of ticks between the orders fills on the chart.

        Zooming in closer, we can see that the entry order has filled a few bars after the entry was submitted, and the exit has as well. Further we also see there are usually many ticks that can be received all at the same time.
        https://drive.google.com/file/d/1sTX...w?usp=drivesdk

        You are looking at the amount of ticks that can be received while an order is being processed and filled.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Hi Chelsea B.,

          According to this,
          https://ninjatrader.com/support/help...tionupdate.htm
          the delay should not exist with Playback:
          "The Sim101 account adds a simulated random delay for processing execution events, but the Playback connection triggers executions immediately"

          The delay happens though with Playback, and it is a normal NT8 behavior, not an issue, as I understand.

          Thank you for clarification.

          Best regards.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by zacharydw00, Today, 05:14 PM
          0 responses
          5 views
          0 likes
          Last Post zacharydw00  
          Started by shahabjet1, Today, 04:47 PM
          0 responses
          12 views
          0 likes
          Last Post shahabjet1  
          Started by aligator, Today, 04:32 PM
          0 responses
          10 views
          0 likes
          Last Post aligator  
          Started by timko, Today, 04:02 PM
          0 responses
          9 views
          0 likes
          Last Post timko
          by timko
           
          Started by asmmbillah, Today, 03:37 PM
          2 responses
          18 views
          0 likes
          Last Post asmmbillah  
          Working...
          X