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

Adding Multiple Instruments to an Indicator

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

    Adding Multiple Instruments to an Indicator

    Hi

    I am attempting to create an indicator that gives me the total volume of all members of the Dow 30 on a single chart of the DJIA index.

    I'm attempting to use Add("<Instrument>", PeriodType.Minute, 1); were <instrument> would be an individual stock. But when I try to Compile it, it gives a message, "No overload for method 'Add' takes '3' arguments": And the error code is; CS1501.

    Even if I cut-and-paste the example straight from the NT user manual, I still get this message. Can someone please tell me what I'm doing wrong here?

    The following is a sample from the manual:

    Examples
    protected override void Initialize()
    {
    // Add a 5 minute Bars object - BarsInProgress index = 1
    Add(PeriodType.Minute, 5);
    // Add a 100 tick Bars object for the ES 12-06 contract - BarsInProgress index = 2
    Add("ES 12-06", PeriodType.Tick, 100);

    // Charts a 20 period simple moving average to the chart
    Add(SMA(20));
    }

    But If I try to use any of the examples, it won't compile



    Yam Digger
    Last edited by yamdigger; 09-10-2008, 11:59 AM.

    #2
    Multi-instrument indicators are currently not available. They will be in NT7 though.

    The line of code you are attempting only works in NinjaScript Strategies. Some people have had success using a Strategy to mimic an indicator. Here is an example of how to do this: http://www.ninjatrader-support.com/v...ead.php?t=6651

    It is not perfect but it is a workaround. The solution is provided as-is though and we cannot offer support for it.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Is there an estimated release (beta) date for NT7?

      Comment


        #4
        Beta end of this year.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by JonesJoker, 04-22-2024, 12:23 PM
        8 responses
        41 views
        0 likes
        Last Post JonesJoker  
        Started by timko, Today, 06:45 AM
        0 responses
        3 views
        0 likes
        Last Post timko
        by timko
         
        Started by Waxavi, 04-19-2024, 02:10 AM
        2 responses
        37 views
        0 likes
        Last Post poeds
        by poeds
         
        Started by chbruno, Yesterday, 04:10 PM
        1 response
        44 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Started by Max238, Today, 01:28 AM
        1 response
        25 views
        0 likes
        Last Post CactusMan  
        Working...
        X