Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Merge Non Back adjusted

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

    Merge Non Back adjusted

    If I am using the Strategy analyzer for WFA on say FESX (set to Merge Non Back Adjusted) from March 2010 to March 2012, and I select FESX 03-14 from the contract list on the left of the strategy analyzer. Will the analyzer then test all the FESX contract that fall within the test period or will it not test at all as FESX 03-14 has no data for that period?

    Second question, assuming the above works and it is does test all contracts in the test period, if I have code in my script that tests for which contract expiry it is trading on, will the script see FESX 03-14 (as that is the contract selected in the strategy analyzer) OR the actual contract expiry it is testing?

    #2
    GKonheiser, with the merge selected and analysis run on 03-14 - that's contract you would be using consistently. NinjaTrader would simply merge in past data from expired contracts into this frontmonth so you have an extended history contract that could also be executed on realtime.

    Comment


      #3
      Thanks, bur how about the logic test in the strategy,

      // Prevent System from trading before coontract is front month.
      if(
      ((Instrument.Expiry.Month == 3) && (Time[0].Date.Month == 12) && (Time[0].Date.Day < iStartTradeDate))
      || ((Instrument.Expiry.Month == 3) && ((Time[0].Date.Month >3) || (Time[0].Date.Month <12)))
      || ((Instrument.Expiry.Month == 6) && (Time[0].Date.Month == 3) && (Time[0].Date.Day < iStartTradeDate))
      || ((Instrument.Expiry.Month == 6) && ((Time[0].Date.Month >6) || (Time[0].Date.Month <3)))
      || ((Instrument.Expiry.Month == 9) && (Time[0].Date.Month == 6) && (Time[0].Date.Day < iStartTradeDate))
      || ((Instrument.Expiry.Month == 9) && ((Time[0].Date.Month >9) || (Time[0].Date.Month <6)))
      || ((Instrument.Expiry.Month == 12) && (Time[0].Date.Month == 9) && (Time[0].Date.Day < iStartTradeDate))
      || ((Instrument.Expiry.Month == 12) && ((Time[0].Date.Month >12) || (Time[0].Date.Month <9)))
      )
      {
      return;
      }

      Will the strategy see the actual contract it is testing on or FESX 03-14?

      Comment


        #4
        It would always see the current front month at the time of testing, so now the 03-14

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by argusthome, 03-08-2026, 10:06 AM
        0 responses
        72 views
        0 likes
        Last Post argusthome  
        Started by NabilKhattabi, 03-06-2026, 11:18 AM
        0 responses
        44 views
        0 likes
        Last Post NabilKhattabi  
        Started by Deep42, 03-06-2026, 12:28 AM
        0 responses
        26 views
        0 likes
        Last Post Deep42
        by Deep42
         
        Started by TheRealMorford, 03-05-2026, 06:15 PM
        0 responses
        31 views
        0 likes
        Last Post TheRealMorford  
        Started by Mindset, 02-28-2026, 06:16 AM
        0 responses
        61 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Working...
        X