Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Some points to clarify rollover and offset of futures

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

    Some points to clarify rollover and offset of futures

    Hello
    I would like to know whether I understood the rollover mechanism of NT correctly:
    1. Default MergePolicy is set in the data tab. This settings I can override with mergepolicy settings per instrument. Is this correct?

    2. You write that roll-over dates are read from NT Server. Is it correct, that when I change a rollover date, it will never ever again overwritten?

    3. If I change the rollover-date, when does NT recalculate the offset value? I assume I do not have to change it manually?

    4. If I edit the offset value, will it be overwritten again when I change the rollover date?

    5. Is it possible somehow to read rollover-dates from a file? It is very time consuming to do all in NT. Especially when I want to test different variants.

    6. As found out, NT does not download all quotes of a contract if the whole chain of future contracts is downloaded. For this reason I have to import each single contract. Question: If the front month changes, does then NT reload all futures contracts again and my imported data is lost?

    thanks for your feedback

    #2
    Hi Beauregard,

    1) Yes.
    2) Yes, rollover dates are provided from server. You can change dates and they will not be overwritten.
    3) We supply offsets at the time of rollover, for a specific date/contract. If you change the date, then you will also have to supply the offset manually.
    4)Rollover offsets will be overwritten from server if you do not also change the rollover date.
    5) We do not support access to this file, but you can find rollover dates and offset here:
    C:\Program Files\NinjaTrader\db\Instruments.txt
    6) No data is "lost" during rollover transitions. Individual contract data is preserved unless you manually delete it. Merging affects only the presentation of prior contract data into the front month contract.
    Last edited by NinjaTrader_RyanM1; 03-12-2012, 01:51 PM.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      OK, thanks for clarification

      Comment


        #4
        Hi Ryan,

        There are a lot of details about Instruments (including dates) in C:\Program Files\NinjaTrader\db\Instruments.txt. But there is no information about offset. I can only find it in Instrument manager. Is there any way how to read offset by program? Some other file?

        Best regards,
        Zdenek

        Originally posted by NinjaTrader_RyanM View Post
        Hi Beauregard,

        1) Yes.
        2) Yes, rollover dates are provided from server. You can change dates and they will not be overwritten.
        3) We supply offsets at the time of rollover, for a specific date/contract. If you change the date, then you will also have to supply the offset manually.
        4)Rollover offsets will be overwritten from server if you do not also change the rollover date.
        5) We do not support access to this file, but you can find rollover dates and offset here:
        C:\Program Files\NinjaTrader\db\Instruments.txt
        6) No data is "lost" during rollover transitions. Individual contract data is preserved unless you manually delete it. Merging affects only the presentation of prior contract data into the front month contract.

        Comment


          #5
          Hi Zdenek,

          Welcome to the NT forums! You're right -- doesn't look like offsets are in that file. This is not supported, but could try with NinjaScript RollOverCollection:
          double offset = Instrument.MasterInstrument.RollOverCollection[0].Offset;
          Ryan M.NinjaTrader Customer Service

          Comment


            #6
            Hi Ryan,

            thanks for the prompt reply but it doesn't work. If there is a problem how to retreat instrument offset I can manually copy offset from Instrument manager to my file. You can forget this request.

            Best regards,

            Zdenek

            Comment


              #7
              Yeah it may take some working around with it but that's where offsets could be retrieved programatically. If you want to try to work with it, here's a snippet that goes through the collection to print the details.

              Code:
              protected override void OnStartUp() 
              {
              	for (int x = 0; x < Instrument.MasterInstrument.RollOverCollection.Count; x++)
              	{
              		Print(Instrument.MasterInstrument.Name + " Contract Month: " 
              				+ Instrument.MasterInstrument.RollOverCollection[x].ContractMonth.ToShortDateString() + " Rolled on: "
              					+ Instrument.MasterInstrument.RollOverCollection[x].Date.ToShortDateString() + " Offset: " 
              						+ Instrument.MasterInstrument.RollOverCollection[x].Offset);
              	}
              }
              Ryan M.NinjaTrader Customer Service

              Comment


                #8
                Thanks a lot. It works.
                Have a nice day.

                Zdenek

                Comment


                  #9
                  Hi

                  I have another question about this topic and could not find the description in the helpfile nor the forum:
                  How does NT define the rollover date of future contracts?

                  thanks

                  Comment


                    #10
                    Hello Beauregard,
                    We generally set the rollover date few days before the contract expiration date.

                    You can find the rollover date from the Misc tab in the Instrument Editor.
                    JoydeepNinjaTrader Customer Service

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by Max238, Today, 01:28 AM
                    2 responses
                    26 views
                    0 likes
                    Last Post NinjaTrader_ChristopherJ  
                    Started by Shansen, 08-30-2019, 10:18 PM
                    25 responses
                    949 views
                    0 likes
                    Last Post NinjaTrader_BrandonH  
                    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
                    4 views
                    0 likes
                    Last Post timko
                    by timko
                     
                    Started by Waxavi, 04-19-2024, 02:10 AM
                    2 responses
                    39 views
                    0 likes
                    Last Post poeds
                    by poeds
                     
                    Working...
                    X