Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NT8 B6 Strategy Analyzer optimizer bug

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

    NT8 B6 Strategy Analyzer optimizer bug

    Hello,

    I am testing a multi-instrument strategy using the Strategy Analyzer and experiencing some odd behavior.

    The primary bars object is the instrument I wish to trade (ES), and the secondary object is used to identify entries (^VIX).

    When I run a simple backtest using the strategy analyzer, it works as expected and trades are made in ES, but when I switch to optimization and run the optimizer, it tries to trade on the secondary bars object (^VIX in this case) and hence the results are garbage.

    Thanks!

    #2
    Hello,
    Thank you for your post.
    Do you see the same outcome with running the SampleMultiInstrument strategy?
    Can you provide the strategy that you ran?
    You can attach your Strategy to your response by going to Tools> Export ? NinjaScript > select your Strategy> > Export. The file will be located under (My) Documents\NinjaTrader8\bin\Custom\ExportNinjaScrip t.
    What optimization settings did you have selected?
    Cody B.NinjaTrader Customer Service

    Comment


      #3
      Yes I can reproduce this behaviour in your sample multi-instrument strategy (once I added some parameter fields, since the template has none), but it is kind of intermittent. It initially seems to work OK, then when you change the optimizer settings (eg. optimize on) and re-run you get the garbage results I described.

      Theres not much point adding my strat here as its based off of your template, I just added 4 parameters for optimization and changed the indicators used etc..

      Comment


        #4
        Hello,
        So I may reproduce this on my end can you provide a screenshot of your optimizer settings you receive this with?
        To send a screenshot with Windows 7 or newer I would recommend using Window's Snipping Tool.

        Click here for instructions

        Alternatively to send a screenshot press Alt + PRINT SCREEN to take a screen shot of the selected window. Then go to Start--> Accessories--> Paint, and press CTRL + V to paste the image. Lastly, save as a jpeg file and send the file as an attachment.

        Click here for detailed instruction
        Cody B.NinjaTrader Customer Service

        Comment


          #5
          JPEGs

          OK here are two captures, the first is the results of the initial optimization using max. profit, the second is the result after I change the optimizer to max. Sharpe ratio. Note in the second that the trades are in ^VIX instead of ES.
          Attached Files

          Comment


            #6
            Hello ours_solaire,

            In the SampleMultiInstrument strategy nothing specifies what instrument to take the trade on, so an optimization can produce trades on the secondary instrument.

            You can control this by submitting the orders specifically to the barsInProgress index needed. For example, you can use the EnterLongLimit() below to enter only on the primary series:
            Code:
            EnterLongLimit(0, true, 1, GetCurrentAsk(), "RSI");

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by jaybedreamin, Today, 05:56 PM
            0 responses
            3 views
            0 likes
            Last Post jaybedreamin  
            Started by DJ888, 04-16-2024, 06:09 PM
            6 responses
            18 views
            0 likes
            Last Post DJ888
            by DJ888
             
            Started by Jon17, Today, 04:33 PM
            0 responses
            1 view
            0 likes
            Last Post Jon17
            by Jon17
             
            Started by Javierw.ok, Today, 04:12 PM
            0 responses
            6 views
            0 likes
            Last Post Javierw.ok  
            Started by timmbbo, Today, 08:59 AM
            2 responses
            10 views
            0 likes
            Last Post bltdavid  
            Working...
            X