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.
    BertrandNinjaTrader Customer Service

    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
        BertrandNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by WeyldFalcon, 08-07-2020, 06:13 AM
        11 responses
        1,422 views
        0 likes
        Last Post jculp
        by jculp
         
        Started by RubenCazorla, Today, 09:07 AM
        0 responses
        4 views
        0 likes
        Last Post RubenCazorla  
        Started by BarzTrading, Today, 07:25 AM
        2 responses
        29 views
        1 like
        Last Post BarzTrading  
        Started by devatechnologies, 04-14-2024, 02:58 PM
        3 responses
        21 views
        0 likes
        Last Post NinjaTrader_BrandonH  
        Started by tkaboris, Today, 08:01 AM
        0 responses
        6 views
        0 likes
        Last Post tkaboris  
        Working...
        X