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

DataSeries in a strategy

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

    DataSeries in a strategy

    Hello, NT experts,
    User manual says all indicator methods accept DataSeries objects as arguments.
    Will DataSeries (like myDataSeries.Set(High[0] - Low[0]) created in a strategy work perperly?

    #2
    Hello Binwang,

    Yes, you should be able to pass this DataSeries into indicators that are looking for a dataseries input. While it should compile, it won't always make sense to use this for all indicators. Let us know if you're having difficulty with any particular implementation.
    Last edited by NinjaTrader_RyanM1; 02-16-2010, 01:31 PM.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      If i want to use multiple dataseries in a multiple instrument strategy, each dataseries matching one isntrument, should the initlization be all the same like this:
      myDataSeries1 = new Dataseries(this);
      myDataSeries2 = new Dataseries(this);
      ...
      Or each one has to be specific to its corresponding instrument?

      Comment


        #4
        This will work, but you will also need to use Add statements for each instrument in the series.


        You'll then have to be sure you're referencing the correct bar object when setting your DataSeries.
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          I found i can only add up to 6 instruments into a strategy.

          If i put more then 6, the strategy will compile but data beyond 6th instrument won't load.

          Should that be the case?

          Comment


            #6
            Hi Binwang,

            No, you should be able to add more than 6 instruments to a strategy. Are you getting any error messages in the log tab of the control center?
            Ryan M.NinjaTrader Customer Service

            Comment


              #7
              No, there is no error message.

              I re-started NT and now the strategy loaded more than 6 instruments.

              Please consider issue resolved. Thanks for yout attention.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by bortz, 11-06-2023, 08:04 AM
              47 responses
              1,611 views
              0 likes
              Last Post aligator  
              Started by jaybedreamin, Today, 05:56 PM
              0 responses
              9 views
              0 likes
              Last Post jaybedreamin  
              Started by DJ888, 04-16-2024, 06:09 PM
              6 responses
              19 views
              0 likes
              Last Post DJ888
              by DJ888
               
              Started by Jon17, Today, 04:33 PM
              0 responses
              6 views
              0 likes
              Last Post Jon17
              by Jon17
               
              Started by Javierw.ok, Today, 04:12 PM
              0 responses
              22 views
              0 likes
              Last Post Javierw.ok  
              Working...
              X