Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

OnBarUpdate Vs. OnExecution

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

    OnBarUpdate Vs. OnExecution

    Hi NT experts,

    I have a generic questions on the difference in handling order status with OnBarUpdate and OnExecution.

    Right now stop and target orders are submitted in OnExecution after verifying the associated entry orders are filled.

    Are there any pitfalls if stop and target orders are submitted in OnBarUpdate after vefifying entries are filled? Suppose CalculateOnBarClose = false.

    #2
    binwang2, the difference would be the slightly different timing when those methods are called then, OnBarUpdate() on each tick (thus can depend on the speed of the market), while OnExecution() would be called for the incoming executions directly, thus OnExecution() would give you more granular access in the event cycle.
    BertrandNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by morrnel, Today, 06:07 PM
    2 responses
    16 views
    0 likes
    Last Post morrnel
    by morrnel
     
    Started by thumper57, Yesterday, 04:30 PM
    6 responses
    20 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Started by sastrades, 05-10-2024, 09:59 AM
    3 responses
    55 views
    0 likes
    Last Post rc5781
    by rc5781
     
    Started by guyonabuffalo, Yesterday, 10:01 PM
    2 responses
    22 views
    0 likes
    Last Post guyonabuffalo  
    Started by reynoldsn, 05-10-2024, 07:04 PM
    5 responses
    28 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Working...
    X