• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

MACD based on SMA values

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

  • StevenV
    started a topic MACD based on SMA values

    MACD based on SMA values

    The MACD indicator that comes with NinjaTrader is based on EMA values. Does anyone have the same indicator but based on SMA values?

    Thanks, Steven

  • NinjaTrader_PaulH
    replied
    Hello California,

    Thanks for your post and welcome to the NinjaTrader forums!

    You are correct, this is a NinjaTrader7 indicator posted in the NinjaTrader7 indicator development forum. NinjaTrader7 scripts are not compatible with NinjaTrader8. Please do not try to import NinjaTrader7 (or earlier) scripts into NinjaTrader8.

    For your convenience and as this was quick, I have converted this to NT8, please note that we do not routinely provide this service.
    Attached Files

    Leave a comment:


  • California
    replied
    Originally posted by NinjaTrader_Matthew View Post
    Hello,

    Attached is a MACD using a SMA rather than the default EMA.
    This indicator does not work in NinjaTrader 8.

    It says: ''This NinjaScript archive was made from an older, imcompatible version of NinjaTrader.''.

    Could you look into this matter, please?
    Attached Files

    Leave a comment:


  • NinjaTrader_PaulH
    replied
    Hello Ram011558,

    Thanks for your post and welcome to the forums.

    To change the version created for SMA in post 3, once you have downloaded and installed the MACDSMA, you would need to follow these short steps to make the changes you want:

    1) Tools>Edit Ninjascript> Indicators

    2) Select MACDSMA

    3) In the code of MACSMA, right mouse click, select "save as" and provide a new name, like MACDTEMA

    4) In the new file of MACDTEMA, go to like 64 and replace SMA with TEMA. Go to line 65 and replace SMA with TEMA. Your lines 64 and 65 should now look like:

    fastSma.Set(TEMA(Input, Fast)[0]);
    slowSma.Set(TEMA(Input, Slow)[0]);


    5) Right mouse click on the chart and select compile.

    6) Once complied, close the file and apply the new indicator to your chart(s)

    Leave a comment:


  • Ram011558
    replied
    Matthew,

    I am after a MACD with TEMA. I tried to change your SMA version without any luck. With you being kind enough to change the EMA to SMA for everyone, I was hoping you would do the same for the TEMA version. I know this is above and beyond your normal scope but it would be greatly appreciate. Thank you.


    Bob

    Leave a comment:


  • StevenV
    replied
    Thanks for the file...Works great.

    Steven

    Leave a comment:


  • NinjaTrader_Matthew
    replied
    Hello,

    Attached is a MACD using a SMA rather than the default EMA.
    Attached Files

    Leave a comment:


  • Radical
    replied
    I don't have one personally, but it would be really easy to modify your current MACD to use SMA instead of EMA...just go through and replace instances of 'EMA' with 'SMA'.

    Leave a comment:

Latest Posts

Collapse

Topics Statistics Last Post
Started by danitralla, Yesterday, 03:33 AM
1 response
20 views
0 likes
Last Post NinjaTrader_ShawnB  
Started by ninjo, Yesterday, 11:54 AM
0 responses
6 views
0 likes
Last Post ninjo
by ninjo
 
Started by deblanka, Yesterday, 08:56 AM
0 responses
13 views
0 likes
Last Post deblanka  
Started by Boonfly8, 03-22-2019, 12:30 PM
7 responses
24 views
0 likes
Last Post sledge
by sledge
 
Started by Sohal, Yesterday, 05:02 AM
2 responses
20 views
0 likes
Last Post techmint  
Working...
X