Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

EMA Strategy Question

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

    #16
    bharrell, unfortunatly we don't provide custom programming services. Maybe someone on the forums can help you out.

    I would recommend starting with the simplest strategy as possible and then adding complexity one layer at a time until it "breaks".

    What I can do is provide you a super simple explaination/demonstration. From what I can tell, you are trying to trade on a "color change", which is really just when the indicator has a peak or trough. Thus, you need to identify when there is a peak or trough. If you think about it, a peak occurs when the most recent value is below the previous value which is above the value before that (looks like this ^ ). Vice-versa for a trough. This can be programmed like this:
    Code:
    if (EMA_Color[0] < EMA_Color[1] && EMA_Color[1] > EMA_Color[2])
        // peak identified - go short or whatever you want it to do
    if (EMA_Color[0] > EMA_Color[1] && EMA_Color[1] < EMA_Color[2])
        // trough identified - do something else, like go long
    Even though I've written this in code, it can be translated to the wizard by using the barsAgo values. EMA_Color[2] means the value of the EMA_Color indicator 2 bars ago.
    AustinNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    633 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    364 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    105 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    567 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    568 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X