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 carnitron, Today, 08:42 PM
            0 responses
            2 views
            0 likes
            Last Post carnitron  
            Started by strategist007, Today, 07:51 PM
            0 responses
            3 views
            0 likes
            Last Post strategist007  
            Started by StockTrader88, 03-06-2021, 08:58 AM
            44 responses
            3,969 views
            3 likes
            Last Post jhudas88  
            Started by rbeckmann05, Today, 06:48 PM
            0 responses
            5 views
            0 likes
            Last Post rbeckmann05  
            Started by rhyminkevin, Today, 04:58 PM
            4 responses
            58 views
            0 likes
            Last Post dp8282
            by dp8282
             
            Working...
            X