Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

CalculateOnBarClose LOW[0] High[0]

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

    CalculateOnBarClose LOW[0] High[0]

    When CalculateOnBarClose is set to false and I am backtesting, what value does the LOW[0] or HIGH[0] return ... does it still "Closeout" the bar and give me the LOW[0] of that closed out bar when loading historical data regardless of the CalculateOnBarClose setting?

    OR should I be using LOW[1] or HIGH[1]?

    Here is my real life problem and the way I am addressing it:
    if (Historical || CalculateOnBarClose == true)
    then I use the LOW[0] and HIGH[0]

    if (!Historical && CalculateOnBarClose == false)
    then I use the CLOSE[0] ... which is the HIGH[0] or LOW[0] since this is a tick right?

    All of this stems from my Tradestation poisioning ... with intrabar calculations the LOW[0] and HIGH[0] of the ticks were really the close of the tick ... I am trying to duplicate this by using the code above.

    Is this correct?

    -Lars

    #2
    In backtesting CalculateOnBarClose has no purpose. It is always true. Close[0], Low[0] etc all return the latest bar at its close.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Latest bar at it's close.

      Originally posted by Josh View Post
      return the latest bar at its close.
      So does that mean when CalculateOnBarClose is set to false that the LOW[0] will bring the last "closed" bar's LOW and not the bar that is in progress?

      -Lars

      Comment


        #4
        "0" always will denote the bar in progress. This has nothing to do with CalculateOnBarClose=true/false. More info: http://www.ninjatrader-support.com/H...BarClose1.html

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by algospoke, 04-17-2024, 06:40 PM
        3 responses
        26 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by bmartz, 03-12-2024, 06:12 AM
        3 responses
        29 views
        0 likes
        Last Post NinjaTrader_Zachary  
        Started by Aviram Y, Today, 05:29 AM
        2 responses
        10 views
        0 likes
        Last Post Aviram Y  
        Started by gentlebenthebear, Today, 01:30 AM
        1 response
        8 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by cls71, Today, 04:45 AM
        1 response
        7 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Working...
        X