Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

TraceOrder confusion

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

    TraceOrder confusion

    What is happening here with respect to the time the order is placed?

    code:
    if (entryOrder == null && (Close[0] > Open[0]))
    {
    entryOrder = EnterLong("mar****rder");
    }

    TraceOrder output:
    3/2/1993 12:00:00 AM Entered internal PlaceOrder() method at 3/2/1993 12:00:00 AM: Action=Buy OrderType=Market Quantity=100 LimitPrice=0 StopPrice=0 SignalName='mar****rder' FromEntrySignal=''

    as well, please see attached image - the date of that market order according to the data box is 3/3/1993

    the way I understand this, the entry condition is met on the close of 3/2/1993. according to the image, the buy order is placed on the open of 3/3/1993. according to the TraceOrder output, the market order is placed on 3/2/1993 at 12:00AM, which is actually BEFORE the entry condition was even met. what is going on here?? i am very confused.

    (i am using yahoo for ohlc daily bars)

    thanks kindly for any help,

    ben
    Attached Files

    #2
    This is expected. You are in a historical/backtest environment and as such all your bars are being processed at the end of each bar. On 3/2 you got the signal to place in the trade. Since 3/2 is already over, the next tradeable location is 3/3 and so that is why you see the order go in on 3/3.
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

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