Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Print function

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

    Print function

    Hello,

    I have a question about the Print function in NT. Let's say I create these variables:
    -entry for the entry price.
    -exit for the exit price
    -stop fot the stop loss

    It would be something like:

    Print(entry+";"+exit+";"+stop);

    When doing a backtest, will I have this information in the Output window? If yes, which steps should I do? Just do the backtest and then go to the output window to see if the information is there?

    Thanks

    Sincerely

    #2
    Hello,

    Yes, the Print() function will work during backtesting. You do not need to do anything different than if the strategy was running against the live market.

    Calling Print() in a backtest will print this information to the Output window
    MatthewNinjaTrader Product Management

    Comment


      #3
      Thank you for the quick reply, I am a little confused, I mean when I test a strategy for example in a 10 years period, and I go to Strategy < Backtest.

      Then I wait for the results and finally I go to the Output Window for getting the informaton of the Print function. Is that right?

      Thanks

      Sincerely

      Comment


        #4
        Yes, the results will be displayed on the output window as the back test runs. You may want to try adding some Time[0] prints to get clarification on how this is working.
        MatthewNinjaTrader Product Management

        Comment


          #5
          Yes, that would be perfect, so I could check the day and time and see if it is doing the calculations correctly.

          Can you give me an example of a Time(0) prints? so I could know the day and time or just the day.

          Thanks

          Sincerely

          Comment


            #6
            Hello,

            You can Print the time just by using:

            Print(Time[0]);
            MatthewNinjaTrader Product Management

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by gravdigaz6, Today, 11:40 PM
            1 response
            7 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Started by MarianApalaghiei, Today, 10:49 PM
            3 responses
            10 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Started by XXtrader, Today, 11:30 PM
            0 responses
            4 views
            0 likes
            Last Post XXtrader  
            Started by love2code2trade, Yesterday, 01:45 PM
            4 responses
            28 views
            0 likes
            Last Post love2code2trade  
            Started by funk10101, Today, 09:43 PM
            0 responses
            9 views
            0 likes
            Last Post funk10101  
            Working...
            X