• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Optimization graph

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

    Optimization graph

    Hi

    Optimization graph question

    Is there a way to export the x and y variables used to plot the graphs?

    For example,

    2d graph:

    Plot net profit and parameter 1

    ... it plots the values. How can I access the actual values so that I can save them to a file or something? I'd like to be Able to export them out of NT.

    Also, why is it so hard to export stuff from NT to excel? Isn't there a similar function to "print" that writes to an excel file??

    Another suggestion; we need to add a "benchmark" to compare our strategy results. For example, how does your strategy compare to a simple buy and hold during the time you actively traded.... a simple percentage plot of the underlying during the time would be enough.. would be nice to overlay your strategy gains and compare them to buy and hold

    #2
    Hello calhawk01,

    Thanks for opening the thread.

    There isn't a way to export the data from an optimization graph. I'll submit a feature request on your behalf.

    Another suggestion; we need to add a "benchmark" to compare our strategy results. For example, how does your strategy compare to a simple buy and hold during the time you actively traded.... a simple percentage plot of the underlying during the time would be enough.. would be nice to overlay your strategy gains and compare them to buy and hold
    I'll submit another ticket for this to be feature requested. I will leave the request more open ended so strategy results could be compared against an arbitrary "benchmark" strategy that would not be limited to a buy & hold.

    As with other feature requests, we cannot present an ETA as they are fulfilled based on the development team's schedule and priorities. Upon implementation the ticket ID can be found publicly on the Release Notes page of the help guide. I'll provide a link below.

    Release Notes: https://ninjatrader.com/support/help...ease_notes.htm

    When I have received tickets for these feature requests, I will update the thread once more.

    EDIT: Ticket IDs:

    Exporting optimization graphs in the Strategy Analyzer - SFT-2645

    Buy and Hold benchmark performance metric - SFT-1674

    Thanks for your feedback!
    Last edited by NinjaTrader_Jim; 01-23-2018, 10:19 AM.
    JimNinjaTrader Customer Service

    Comment


      #3
      Thanks.

      The reason why for need these values is bc I want to know how my pnl changes as the values on my parameter change.

      When we run optimization, you can see this on the graph, however in need to export these so that I can analyze them further using R and implement machine learning techniques.

      I could theoretically run the optimizer, and "keep" the top 1000 results and then export those into excel and see how many variable changes and how that impacts my pnl.

      However, is there a line of code that I can add to my strategy, that, once I run my optimizer, and only then, the "end results" (the parameter used and net pnl) of all the iterations that the system is running can be printed on the output window?

      Also how many top results can n8 actually save? Mine freezes at around 800 iterations if I try to save max iterations (1600 top results)

      Comment


        #4
        Hello calhawk01,

        There isn't a parameter that will output this information to the output window in one go. If you wanted, you could add your own code to OnExecutionUpdate() to output any desired performance metrics.

        I am not aware of any limitations for "Keep best # results." There may be a delay with garbage collection and memory usage. Making sure that you have "Keep best # results" less than the maximum number of iterations, could you test again with the Windows Task Manager open so we can observe memory usage?

        We will want to give enough time for garbage collection to kick in if NinjaTrader looks frozen. Please give NinjaTrader some time and see if memory utilization eventually frees to continue the backtest.

        Also, you may be able to optimize your strategy so it can perform better on optimization backtests. Please see IsInstantiatedOnEachOptimizationIteration and the Best Practices linked below for more information.

        IsInstantiatedOnEachOptimizationIteration - https://ninjatrader.com/support/help...niteration.htm

        Best Practices (See Resetting class level variables for Strategy Analyzer Optimization) - https://ninjatrader.com/support/help...urceManagement

        I look forward to being of further assistance.
        JimNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Jschmelz, Today, 04:45 PM
        1 response
        7 views
        0 likes
        Last Post NinjaTrader_Marco  
        Started by sisenberg, Today, 08:06 PM
        1 response
        7 views
        0 likes
        Last Post sisenberg  
        Started by priceisking, Today, 07:44 PM
        0 responses
        5 views
        0 likes
        Last Post priceisking  
        Started by saltminer, Today, 06:06 PM
        0 responses
        5 views
        0 likes
        Last Post saltminer  
        Started by KennyK, Today, 05:25 PM
        0 responses
        7 views
        0 likes
        Last Post KennyK
        by KennyK
         
        Working...
        X