Announcement

Collapse
No announcement yet.

MACD using Simple Moving Avg

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

  • MACD using Simple Moving Avg

    Hi,

    How can I use Simple Moving Avg in macd function?
    It uses WMA by default.

    For Example, if I add a macd study in the chart there's an
    option to choose SMA in the edit chart screen.

    But when I try to make EFS program I don't know how to
    change it to SMA instead of WMA.

    Thanks.

  • #2
    Re: MACD using Simple Moving Avg

    josephkim888
    Actually the macd() and related macdSignal() and macdHist() functions use an EMA and not a WMA to calculate the oscillator and a SMA to calculate the signal line. That said they do not have an option to calculate the oscillator using a SMA.
    Your options are to either use the legacy MACDStudy() function [as an example see the basicMACD.efs available here] or to create your own function to calculate the oscillator.
    Alex


    Originally posted by josephkim888
    Hi,

    How can I use Simple Moving Avg in macd function?
    It uses WMA by default.

    For Example, if I add a macd study in the chart there's an
    option to choose SMA in the edit chart screen.

    But when I try to make EFS program I don't know how to
    change it to SMA instead of WMA.

    Thanks.

    Comment

    Working...
    X