Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Indicators Affecting the Behavior of Other Indicators

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

    Indicators Affecting the Behavior of Other Indicators

    This is probably a pretty dumb question, but here goes...

    If I have a set of individually pretty simple indicators that I want to interact with each other, should I:

    a) write each simple indicator individually (compiled serparately) and then write a master indicator that takes the values of each preceding indicator and uses them to affect the flow of subsequent ones

    or

    b) write this as one giant indicator

    or

    c) am I now talking about a strategy and I should learn more about those? (I have no interest in an automated strategy at this point, these indicators are purely to put the information on the chart relevant to discretionary decision making.)

    As a simple example, presume I have an indicator to detect trend-up, trend-down or no trend. If the trend is up, I want to run some tests to see if the trend is healthy, ending, etc. If the trend is down, the topping tests wouldn't be run, others would, etc.

    C# programming is pretty new to me, I do have a little background in SQL. If I was writing this in SQL I'd write each "indicator" as its own procedure and then write a master procedure controlling the action (option a), but I'm a little concerned my C# is inadaquate for passing data out of indicators to others, etc.

    What do you think? Should I suck it up and learn more C# or is what I am trying to do properly a strategy and I should be learning those or do people write one massive indicator at times?

    Thanks in advance.

    #2
    Hello Grasul,

    What you're looking for is an indicator. A strategy will have order placement capability and an indicator is best for calculating and displaying information.

    There shouldn't be too much "interaction" with multiple indicators. You can only read values from other indicators. If the value you're accessing is a plot, there isn't any extra code required to access. For accessing non-plot values, this sample can help with the technique required:


    How you design the indicator(s) is up to you, but from your description it sounds like it could be best all in one indicator. If all the intermediary calculations are used but not plotted, then it will be more efficient and likely easier to code having it all in one. Knowing C# is helpful, but not necessary to learning how to create indicators. These tutorials are a good way to get started:
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Thanks RyanM,

      that's not the answer I'd have expected so I am very glad I asked the question.

      It is the answer I was hoping for, because I think it fits my expertise level the best, but I didn't want to go too far down the road of writing one indicator without asking.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by mattbsea, Today, 05:44 PM
      0 responses
      1 view
      0 likes
      Last Post mattbsea  
      Started by RideMe, 04-07-2024, 04:54 PM
      6 responses
      31 views
      0 likes
      Last Post RideMe
      by RideMe
       
      Started by tkaboris, Today, 05:13 PM
      0 responses
      2 views
      0 likes
      Last Post tkaboris  
      Started by GussJ, 03-04-2020, 03:11 PM
      16 responses
      3,281 views
      0 likes
      Last Post Leafcutter  
      Started by WHICKED, Today, 12:45 PM
      2 responses
      19 views
      0 likes
      Last Post WHICKED
      by WHICKED
       
      Working...
      X