Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Yearly Bars

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

    Yearly Bars

    I'm looking for a solution for Yearly Bars indicator which I can use as input series for another indicator.
    Is there a ready solution? Please advise who knows. Thanks.
    Igor

    #2
    Welcome to our forums Igor - could you please clarify a bit more for us what you're looking to do? You can right now create a so called MultiSeries chart in NT, which could add yearly bars as well and then you could specify this to be used as Input Series for your indicators.

    Comment


      #3
      Yearly Bars

      Bertrand,
      I'm an option trader, very aggressive one. I buy when the end of the world is coming. So, I need visualize market levels for particular instruments when extreme moves are done. So, using previous YearlyBars I want calculate and visualized ATR and StdDev fixed levels lines for the current year on daily charts. I want to use this YearlyBar Indicator as input serias in Bollinger Band, Keltner Channel like indicators.
      In the future I will like to have option expiration Monthly (not calendar month) bars Indicator as well.
      I would greatly appreciate your advise how I can achieve my task.
      Igor

      Comment


        #4
        Hello,

        You can first Add() the yearly bar to the Initialize() method of your code:

        Code:
        		protected override void Initialize()
        			{
        				Add(PeriodType.Year, 1);	
        			}
        With this added, you can now get any value from that bars series by using BarsArray[1]

        Code:
        			protected override void OnBarUpdate()
        			{
        
        				double yearADX = ADX(BarsArray[1], 14)[0];
        				
        			}
        I would suggest reading through the following link on multi-series indicators which covers a few key points on this type of script:

        MatthewNinjaTrader Product Management

        Comment


          #5
          I will. Thank you very much for your help.
          Igor

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by CarlTrading, 05-11-2026, 05:56 AM
          0 responses
          27 views
          0 likes
          Last Post CarlTrading  
          Started by CarlTrading, 05-10-2026, 08:12 PM
          0 responses
          20 views
          0 likes
          Last Post CarlTrading  
          Started by Hwop38, 05-04-2026, 07:02 PM
          0 responses
          183 views
          0 likes
          Last Post Hwop38
          by Hwop38
           
          Started by CaptainJack, 04-24-2026, 11:07 PM
          0 responses
          335 views
          0 likes
          Last Post CaptainJack  
          Started by Mindset, 04-21-2026, 06:46 AM
          0 responses
          260 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Working...
          X