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

Help needed with multi series

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

    Help needed with multi series

    Hello,
    (1) I'm new to NT script and try to start from simple.
    (2) My primary series is CL 03-11 2 Renko and try to access the previous High and Low from 10 Renko. I've done the following but check with the output window, the values aren't what I want. Please point out where I'm wrong.

    protected override void Initialize()
    {
    AddRenko("CL 03-11", 10, MarketDataType.Last);
    }

    if(CurrentBar < 1);
    return;

    if(BarsInProgress == 1)
    {
    hi = High[1];
    lo = Low[1];
    }

    Print(hi.ToString("00.00")+ " " + lo.ToString("00.00"));

    DrawRay("01", false, 1, hi+TickSize*10, 0, hi+TickSize*10, Color.Silver, DashStyle.Dot, 1);
    DrawRay("02", false, 1, lo-TickSize*10, 0, lo-TickSize*10, Color.Silver, DashStyle.Dot, 1);
    Attached Files
    Last edited by denhu fazu; 01-18-2011, 12:28 PM.

    #2
    Hello denhu fazu,

    The code matches your description. Is the issue caused by the semicolon at end of if statement? This shouldn't go there.

    if(CurrentBar < 1);
    return;
    Last edited by NinjaTrader_RyanM1; 01-18-2011, 02:02 PM.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Hello RyanM,
      (1) I've checked my code and confirmed I've used the correct semicolon. The problem still remained.

      Comment


        #4
        Just to clarify - Did you remove the semicolon indicated in my first reply? It does not belong at the end of the if statement.
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          Hello RyanM,
          (1) Thanks for solving my problem.
          (2) I'm sorry for misinterpreting your reply and what a silly mistake I've made.
          (3) By the way, does Kinetick (EOD) provide forex (eg $EURUSD ) intraday tick historical data? It seems like I fail to load any.

          Comment


            #6
            My pleasure and thanks for the follow - up. It's good to hear that sorted out the issue.

            Kinetick EOD provides only daily bars and higher (weekly, monthly, etc). If you are interested in lower time frame intervals like tick, this is available with a paid subscription only.
            Ryan M.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by pechtri, 06-22-2023, 02:31 AM
            8 responses
            122 views
            0 likes
            Last Post Nyman
            by Nyman
             
            Started by frankthearm, 04-18-2024, 09:08 AM
            16 responses
            64 views
            0 likes
            Last Post NinjaTrader_Clayton  
            Started by habeebft, Today, 01:18 PM
            1 response
            5 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by benmarkal, Today, 12:52 PM
            2 responses
            13 views
            0 likes
            Last Post benmarkal  
            Started by f.saeidi, Today, 01:38 PM
            1 response
            7 views
            0 likes
            Last Post NinjaTrader_BrandonH  
            Working...
            X