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

how to load historical data in strategy?

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

    #31
    Hello toughgetsgoing,

    That I know of, there are no sources of unlimited free tick or minute data from the market.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #32
      Hi Chelsea,

      I am able to backtest my strategy properly now. I have some technical question.

      On start of every new day, I do an asynchronous bars request for past 100 days (daily data). By the time I receive the data, all the intraday updates (OnBarUpdate) are already processed.

      Is it possible to request the data synchronously instead? (without using C# constructs like WaitHandles). On start of every new day: I would like to request past 100 days daily data, process the data and then start processing OnBarUpdate updates.

      Comment


        #33
        Hello toughgetsgoing,

        I am not aware of any safe ways to perform this sequentially.

        I think a thread sleep would be necessary but this not supported by (and is always advised against by) NinjaTrader Support to do.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #34
          Thanks Chelsea. I am using Thread.Sleep function as of now and the functionality in backtest is working as i expect. I don't expect this to cause any issue in live trading as this will be called only once at the start of the strategy.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by rocketman7, Today, 02:12 AM
          1 response
          16 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Started by briansaul, Today, 05:31 AM
          1 response
          12 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Started by PaulMohn, Today, 03:49 AM
          1 response
          12 views
          0 likes
          Last Post NinjaTrader_BrandonH  
          Started by frslvr, 04-11-2024, 07:26 AM
          6 responses
          106 views
          1 like
          Last Post NinjaTrader_BrandonH  
          Started by trilliantrader, 04-18-2024, 08:16 AM
          6 responses
          26 views
          0 likes
          Last Post trilliantrader  
          Working...
          X