New Members: Be sure to confirm your email address by clicking on the link that was sent to your email inbox. You will not be able to post messages until you click that link.

Scan for a moving average of an indicator

I have been trying to write a scan for the 50 Week SMA of the Weekly Williams%R(60), but having no success. If someone could help on this matter, I would be most appreciative. Thank you.

Comments

  • markdmarkd mod
    edited September 21
    and [weekly sma(50, weekly Williams %R(14)) < 20 ]

    For an sma( ), the first term is the number of elements to average, and the second term is what value to average. Usually, its a price like high, low or close. But it can be indicator value as well.

    The second thing is, *both* the function (sma in this case) AND the terms inside it have to have a time frame modifier (daily weekly monthly), if they can take a time frame modifier. Williams %R can take a time frame modifier, so, it's "weekly sma(..." AND "weekly Williams..". NOTE: if you omit or mix time frame modifiers, the scan may run even if it doesn't give you an editor error or a syntax error, but the results will not be what you expect.

    (the exception is "daily"; the scan engine assumes a value is daily if there is no time frame modifier, so if you mean daily, you don't have to write it in the scan. No harm if you do, though.)
  • Thank you.
Sign In or Register to comment.