Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

high & lows

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

    high & lows

    Is there a way to determine what the previous high and low values are?

    #2
    Hello pman777,

    Yes there is. If you are looking for the previous days high and low, NinjaTrader does come with the PriorDayOHLC indicator that you can use. See the link below for more information about the PriorDayOHLC indicator.
    http://www.ninjatrader.com/support/h...r_day_ohlc.htm

    Alternatively, if you are looking for the highest price value over a lookback period you can use the HighestBar() or LowestBar() to get the number of bars ago the value was. For example:

    Code:
    //Gets the number of bars ago the high was in a 15 bar period
    int testval = HighestBar(Close, 15);
    Print("High close price of the last 15 bars is: "+Close[testval]);
    LowestBar(): http://www.ninjatrader.com/support/h...?lowestbar.htm
    HighestBar(): http://www.ninjatrader.com/support/h...highestbar.htm

    Please let me know if I can be of further assistance.
    JCNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    67 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    36 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    61 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    62 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    53 views
    0 likes
    Last Post CarlTrading  
    Working...
    X