Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Indicator values inside a strategy

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

    Indicator values inside a strategy

    How do I retrieve indicator values that are based on bar-by-bar execution inside a strategy that is tick-by-tick?

    I am using the ParabolicSAR indicator inside a tick based strategy, and I have noticed that it plots very different values to the same indicator with the same parameters, except my second instance of the ParabolicSAR is not part of the strategy, and is bar based.
    So when I access the ParabolicSAR values from within the strategy, they are not what I expect. I have tried using FirstTickOfBar to simulate bar-by-bar values for ParabolicSAR, but that does not give me the bar-by-bar values I need.

    #2
    astrolobe,

    In your strategy, use a filter for if (FirstTickOfBar) and then access the values of the just closed bar with [1] index. The opening of a new bar is the same event as the closing of the previous bar so that would be how to get values on a bar by bar basis.

    Please ensure you are on 6.5.1000.14 if you are using ParabolicSAR. There had been changes a few versions back so if you are on an old version you may not have the correct indicator.
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by charlesugo_1, 05-26-2026, 05:03 PM
    0 responses
    60 views
    0 likes
    Last Post charlesugo_1  
    Started by DannyP96, 05-18-2026, 02:38 PM
    1 response
    147 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 05-11-2026, 05:56 AM
    0 responses
    162 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 05-10-2026, 08:12 PM
    0 responses
    97 views
    0 likes
    Last Post CarlTrading  
    Started by Hwop38, 05-04-2026, 07:02 PM
    0 responses
    284 views
    0 likes
    Last Post Hwop38
    by Hwop38
     
    Working...
    X