Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Saved Strategy Results not showing in Strategy Analyzer

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

    Saved Strategy Results not showing in Strategy Analyzer

    I had about 5 years worth of strategies and their backtest results saved on Ninjatrader 7. All of a sudden, all the saved backtest and optimizer results no longer appear. The strategies themselves are still there, as well as the backtest or optimizer saved file name show in the left part of the navagation pane, but no matter what results you click on, it just shows zeros for everything. I tried repairing the database but that didn't work. The only thing I changed recently was moving from a free version of NT7 to a lifetime license, but I dont see how that would affect the strategy results. Any help would be greatly appreciated!

    #2
    Hello nmk85roll,

    When you say "free version of NT7" are you referring to the Free Live license key which does not allow for live trading, does not allow for running strategies, and will not allow you to open the Strategy Analyzer, or are you referring to the Simulation License key which does allow for opening the Strategy Analyzer?


    The saved backtest results are saved in the database. Has the database been reset or deleted and recreated? (This would wipe out the saved results)

    Do you have a backup exported in the Documents\NinjaTrader Backup\ folder from a date where the results where still available?

    Below is a link to the help guide on restoring a backup.


    Do you still have the historical data? If so, you can run the optimization or backtest again and re-save the results.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      I've always been able to use Strategy Analyzer, I was live trading 5 years and then stopped so I just assumed that it moved back to the simulation license key. Even now, I can't save NEW strategy results either with my paid license so that would lead me to believe the license isn't the issue. Unfortunately, I did not create a back up in a long time so I can't resort to that. Any other ideas, or more importantly why saving strategies wouldn't work for me now? thanks for your help!

      Comment


        #4
        Hello nmk85roll,

        You may be using an invalid license that is expired. An expired leased license would not allow the Strategy Analyzer to be opened. The Free License would not allow the Strategy Analyzer to be opened. However, a Lifetime license, Leased license that is not expired and is still active, or the Simulation License will allow the Strategy Analyzer to be opened.

        Was the license a lifetime license?


        The logs would be in the database for NinjaTrader 7. If something happens to the database file, like being reset, deleted, or the computer itself gets a new harddrive etc, the logs will be lost.
        If you do not have a backup saved, all the real-time executions, strategy logs, atm strategy templates, etc are gone.

        NinjaTrader 8 has been improved to save these logs as separate xml files instead of saving these in the database. Same with atm strategy templates.

        Moving forward, I recommend to make backups every once in a while incase something happens to your computer and you lose files from the filesystem. These backups will go to the Documents\NinjaTrader Backup folder. You can save those to a cloud service like drop-box or google drive, and ensure your data from your computer never gets lost.


        Regarding why strategy analyzer logs cannot be saved now, may I confirm that you are using either a Simulation License, Lifetime License, or a Leased License that is still valid?
        (Help -> About)

        Are results appearing after running a new backtest?

        Do any errors appear on the Log tab of the Control Center when attempting to click Save?

        Are you using the latest release of NinjaTrader 7, 7.0.1000.42?
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Based on your message, the one I was previously using would have had to be the simulation license as I had regular access to Strategy analyzer. Now, i have a lifetime license so its definitely not expired. Results DO appear after a back test as I would expect.

          The log shows a LOT of errors if I try to open the results of a previous strategy, 18 to be exact. they all say "Strategy xxxxxxxxxxxxx: unable to deserialize user data, there was an error reflecting type "NinjaTrader.Strategy.xxxxxx"

          I am using NT7 7.0.1000.40...

          Comment


            #6
            Hello nmk85roll,

            Please update to the latest version of NinjaTrader 7, 7.0.1000.42 and also reset instruments.


            I see that you're running an older version of NinjaTrader 7. The newer version contains many critical updates to the database. Please update NinjaTrader 7 and reset your instruments:

            First, to update NinjaTrader, please follow the steps below:
            • First get your license key from NinjaTrader under Help> License Key then exit NinjaTrader
            • Click on the link: https://ninjatrader.com/PlatformDirect
            • Enter your license key and press Submit
            • Under 'Prior Releases' select the version next to 'NinjaTrader 7' to begin your download.
            • Critical: Before running the installer, ensure NinjaTrader is closed.

            Lastly, to reset your instruments, please follow the steps below:
            • Disconnect from your data feed: NinjaTrader Control Center> File> Disconnect> Select your data feed
            • Reset your Instruments: NinjaTrader Control Center> Tools> Options> Data tab> Reset Instruments>OK
            • Restart NinjaTrader> Connect (NinjaTrader Control Center> File> Connect> Select your connection

            After this, focus on saving logs.

            When saving a new log of strategy results, do any errors appear on the Log tab of the Control Center?


            With the error: "Strategy xxxxxxxxxxxxx: unable to deserialize user data, there was an error reflecting type "NinjaTrader.Strategy.xxxxxx", this means what was saved cannot be re-run as either the strategy itself has changed (such as from an update from the developer), is no longer available, or the database has become corrupted and the relational record that maps the saved log to a strategy currently imported in NinjaTrader was lost.

            This should not prevent new logs from being saved.
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              So I upgraded per your directions, and now I can't even get new backtest results to display, it gets stuck on the "Backtest in process..." even though the status bar shows it completed.

              The strategies are available, nothing changed as i wrote them, so that only leaves a corrupted database... however that doesn't explain why I can't even run new strategies now, see results, or even save them.

              Comment


                #8
                Hello nmk85roll,

                Do any errors appear on the Log tab of the Control Center when running a backtest?

                If you print the time of the bar to ensure the strategy is processing data, does this appear in the output window?
                Chelsea B.NinjaTrader Customer Service

                Comment


                  #9
                  Ok, so i deleleted and reinstalled/compiled some of my newer strategies. They compile fine, and now back test results WILL indeed show. However, we are back to not being able to save any new results or retrieve any old ones. Upon trying to save a new backtest result, I get the following error:

                  "Unable to save one or more of your strategies: There was an error reflecting type "NinjaTrader.Strategy.xxxxxx"

                  Comment


                    #10
                    Hello nmk85roll,

                    Does this also happen with the SampleMACrossover included with NinjaTrader?
                    (This would let us know if it's db corruption or an issue with the custom script)
                    Chelsea B.NinjaTrader Customer Service

                    Comment


                      #11
                      Just tried SampleMACrossover and saving results, same issue and error in the log.

                      Comment


                        #12
                        Hello nmk85roll,

                        Thank you for confirming this.

                        This may be a corrupted database.

                        Rename your database by following the steps listed below. Doing so will cause NinjaTrader to create a new database on start up. Because of this, ATM strategy templates, session templates, custom instruments and instrument lists will need to be recreated.

                        To rename the database:
                        • Shutdown NinjaTrader
                        • Open the Documents > NinjaTrader 7 > db folder
                        • Right click on NinjaTrader.sdf and select "Rename"
                        • Rename the file 'OLDNinjaTrader.sdf'
                        • Finally, start NinjaTrader
                        Unfortunately the following items stored in the old database will be lost: ATM Strategy templates, Session templates, Instrument Lists / Custom Instruments, historical trade execution data, and NinjaScript Strategy instances.

                        After the database is recreated, please test the SampleMACrossover included with NinjaTrader once more.

                        If the same error occurs, I would like to schedule a call with you to investigate.
                        Chelsea B.NinjaTrader Customer Service

                        Comment


                          #13
                          Quick check, will this also delete all of my historical data?

                          Comment


                            #14
                            Also, just looked at my db folder, i already have TWO .sdf files both have been modified in the past 24 hours, could that be causing a problem?

                            NinjaTrader.Old.sdf
                            NinjaTrader.sdf

                            Comment


                              #15
                              Hello nmk85roll,

                              No this will not remove the historical data.

                              The database will be modified if you have placed an order, saved a template, saved an atm strategy, or run the repair or reset.

                              The NinjaTrader.Old.sdf appears when running the reset.
                              Chelsea B.NinjaTrader Customer Service

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Haiasi, 04-25-2024, 06:53 PM
                              2 responses
                              16 views
                              0 likes
                              Last Post Massinisa  
                              Started by Creamers, Today, 05:32 AM
                              0 responses
                              5 views
                              0 likes
                              Last Post Creamers  
                              Started by Segwin, 05-07-2018, 02:15 PM
                              12 responses
                              1,786 views
                              0 likes
                              Last Post Leafcutter  
                              Started by poplagelu, Today, 05:00 AM
                              0 responses
                              3 views
                              0 likes
                              Last Post poplagelu  
                              Started by fx.practic, 10-15-2013, 12:53 AM
                              5 responses
                              5,407 views
                              0 likes
                              Last Post Bidder
                              by Bidder
                               
                              Working...
                              X