Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

How to print more information onto the output window?

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

    How to print more information onto the output window?

    Hello,

    My strategy calculates on each tick and runs on a 30 minute time period.
    The strategy only works for the first 30 minutes of each day. When I run this strategy on a backtest on one day of data, (say: Start Time = 11/15/2021, End Time = 11/15/2021), so much information is printed on the output that it says:

    "You have reached the maximum threshold of the NinjaScript Output window. Some of your output messages have been suppressed." I realize that the output window has a character limit.

    Because of this, the output only has information printed from 11/15/2021 3:00 PM to 11/15/2021 4:00 PM so I can't see what happens when the strategy actually performs actions @ 8:30 AM to 9:00 AM which is suppressed.

    How can I capture and save all of the info that is suppressed and printed on the output window?

    #2
    If you wrote your output to a file, there would be no limit.

    Comment


      #3
      Hello Don22Trader1,

      Thanks for your post.

      The Output Window is limited and has a maximum number of lines.

      If a large amount of data is being tested, I would recommend instead writing this to a file to avoid the maximum number of lines allowed in the Output Window.

      Below is a link to a reference sample that demonstrates writing data to a file.
      https://ninjatrader.com/support/helpGuides/nt8/using_streamwriter_to_write_to.htm

      As well as a link to an example script that writes condition information to a file.
      https://ninjatrader.com/support/foru...nce#post100192

      Let us know if we may assist further.
      Brandon H.NinjaTrader Customer Service

      Comment


        #4
        Brandon,
        How do i limit the prints to once per trade instead of on every bar update?

        Comment


          #5
          You could use OnExecutionUpdate to detect when a new trade is executed and do your logging there...
          Bruce DeVault
          QuantKey Trading Vendor Services
          NinjaTrader Ecosystem Vendor - QuantKey

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by MacDad, 02-25-2024, 11:48 PM
          7 responses
          158 views
          0 likes
          Last Post loganjarosz123  
          Started by Belfortbucks, Today, 09:29 PM
          0 responses
          7 views
          0 likes
          Last Post Belfortbucks  
          Started by zstheorist, Today, 07:52 PM
          0 responses
          7 views
          0 likes
          Last Post zstheorist  
          Started by pmachiraju, 11-01-2023, 04:46 AM
          8 responses
          151 views
          0 likes
          Last Post rehmans
          by rehmans
           
          Started by mattbsea, Today, 05:44 PM
          0 responses
          6 views
          0 likes
          Last Post mattbsea  
          Working...
          X