Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Add(PeriodType.Tick, 1) ;

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

    Add(PeriodType.Tick, 1) ;

    Looking for granularity on entry on say a 5 minute bar and adding the tick component within a 5 minute bar as below -

    Add(PeriodType.Tick, 1) ;

    But how can this be used if you want the difference between the two - something like

    Var MyVal = Close(0) - (PeriodType.Tick,1) ;

    without errors!


    Thanks
    Last edited by alpha_bet; 07-09-2015, 06:53 AM.

    #2
    Hello alpha_bet,

    Thanks for your post and welcome to the forums!

    When adding a dataseries you are creating a multitimeframe strategy and to reference a dataseries requires using an added index. Please review this section of the helpguide as it is critical to understanding how it all works: http://ninjatrader.com/support/helpG...nstruments.htm

    To answer your question:

    Var MyVal = Closes[0][0] - Closes[1][0]; // diff between current 5 minute bar Close and current tick Close.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    571 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    330 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    101 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    548 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    549 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X