Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

MACD from Ema to Sma

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

    MACD from Ema to Sma

    Hi All,

    Reaching out to see if anyone has modified a MACD from Exponential to Simple? I would like to be able to switch the Fast, Slow, and Smooth to either Ema or Sma. I tried tweaking the MACD that comes with NT8, but not sure I did anything.

    I turned the slowEma to slowSma, but again not sure that worked correctly. Also, I have no idea where to even start with the Smooth making it either Ema or Sma.

    Thanks in advance.
    -Shaun

    #2
    Hello Shaun,

    I'm not aware of an existing indicator as you have described, this thread will remain open for any community members that may know of this or who would like to build this for you as a convenience.

    The equation for the fast and slow ema is the same, but uses different inputs for the period.
    Try comparing the following to the EMA indicator's code:

    constant1 = 2.0 / (1 + Fast);
    constant2 = (1 - (2.0 / (1 + Fast)));
    double fastEma0 = constant1 * input0 + constant2 * fastEma[1];

    Instead, you could replace this with the code from the SMA indicator.


    You can also contact one of our professional NinjaScript Consultants who would be eager to create or modify this script at your request or assist you with your script. Please let me know if you would like our business development follow up with you with a list of professional NinjaScript Consultants who would be happy to create this script or any others at your request.
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    559 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    324 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    101 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    546 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    547 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X