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

Order of Operations

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

    Order of Operations

    Hello,

    Is there a help page that discusses the order of operations when a tick or price change comes in?

    My question is, is it deterministic that OnBarUpdate is executed for indicators first and then strategies? I'm realizing that logic I put into a custom indicator must be done in OnBarUpdate for the indicator before my strategy runs OnBarUpdate as it relies on the indicator to be updated for that tick (typically, the first tick of a bar) or price change is evaluated.

    Thanks,
    Matt

    #2
    Hello StealthM93,

    I don't know of a specific resource that just directly says what you stated but that would be the general expectation. The indicator will need to process before the strategy can access its values. There is one comment in the help guide that mentions you need to call the indicator to get its values and to have it calculate but not that it happens first (it does).



    JesseNinjaTrader Customer Service

    Comment


      #3
      Thank you, Jesse!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by geddyisodin, Today, 05:20 AM
      6 responses
      34 views
      0 likes
      Last Post geddyisodin  
      Started by trilliantrader, Today, 03:01 PM
      0 responses
      3 views
      0 likes
      Last Post trilliantrader  
      Started by pechtri, 06-22-2023, 02:31 AM
      9 responses
      122 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by frankthearm, 04-18-2024, 09:08 AM
      16 responses
      67 views
      0 likes
      Last Post NinjaTrader_Clayton  
      Started by habeebft, Today, 01:18 PM
      1 response
      8 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Working...
      X