Announcement

Collapse
No announcement yet.

Negative offsets in efs MA's

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

  • Negative offsets in efs MA's

    Hi,

    I have a study that I have created that uses the MAStudy() function.

    I have used a negative offset:

    MAStudy(5, -3, "Close", MAStudy.WEIGHTED);

    In my efs script. When I run it through the backtester it works great but when I use it as a sutdy in my day to day operations it returns null?

    Anyone know if this is a bug or not? I have been using a negative offset MA for some time but am just now using it in a study.


    Thanks,

    Jon

  • #2
    Jon,

    You will need at least MA length + offset bars before you get non-null results

    Just put a check in for a return of NULL and if you get it, just return. I suspect this is your problem.

    G
    Garth

    Comment

    Working...
    X