Announcement

Collapse
No announcement yet.

Offset moving average math

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

  • Offset moving average math

    Hi
    Can anyone tell me mathematically what the offset moving average is doing? Lets say I have a 21 day moving average that I am offseting 5 days into the future. I get the 21 day ma part but how do I put the offfset into the future variable into it? Any help will be greatly appreciated.

    chris

  • #2
    setback/set forward

    Hi Chris,

    I use moving average setbacks this way. No math involved
    for the perceptive eye.



    ~j

    Comment


    • #3
      Thanks for your reply. I was thinking more how would I calculate it all I had was the prices and a pad of paper. So the actual formula used to get the indicator.

      Thanks,
      chris

      Comment


      • #4
        Chris
        The calculation is the same as that of the moving average except that you "shift" the result fowards (or backwards) by the amount of the offset.
        Using your 21 day MA as an example to calculate it you would add the last 21 prices (starting from today's) and divide the result by 21. Then you would plot that value on today's bar.
        If you now want to offset that MA forward by 5 days into the future then instead of adding the last 21 days starting from today you add the 21 days starting from 5 days ago (ie the offset) and then divide by 21. The resulting value you plot on today's bar. You have now displaced forward the same 21 day MA.
        Hope this helps
        Alex

        Comment


        • #5
          Thank you. That helps alot.

          Regards,
          chris

          Comment

          Working...
          X