Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Read existing indicator values

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

    Read existing indicator values

    Hello,

    I have a few indicators added to my chart. For example: RSI, Momentum, Bollinger and 2 custom indicators. If I want to read the value of each of these indicators, how would I access them from a C# based custom indicator (in the OnBarUpdate() method)?

    I am interested in retrieving the current value of each of the indicator for every single tick. Every single indicator is showing in the data box.

    Please help.

    Thanks

    #2
    Welcome to our forums - you can directly call the indicator method in your custom script, for example

    double upperValue = Bollinger(2, 20).Upper[0];

    will get you the Upper value of the 20 period 2 deviation Bollinger Bands.

    Similiar for your other studies including the custom indicators, if you want to process on each tick in realtime or replay, just run the calling study with CalculateOnBarClose set to false.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    82 views
    1 like
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    43 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    64 views
    2 likes
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    68 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    56 views
    0 likes
    Last Post CarlTrading  
    Working...
    X