BullCharts Forum Homepage
Forum Home Forum Home > BullCharts > BullScript
  New Posts New Posts RSS Feed: The Quick MA
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

The Quick MA

 Post Reply Post Reply
Author
Message Reverse Sort Order
maximo View Drop Down
BullCharts Guru
BullCharts Guru
Avatar

Joined: 02 Sep 2006
Location: Australia
Posts: 232
Post Options Post Options   Quote maximo Quote  Post ReplyReply Direct Link To This Post Topic: The Quick MA
    Posted: 10 Feb 2018 at 9:56pm
[Description="The Quick MA is a phase adjusted exponential moving average with almost no lag and still maintains smoothness."]
[Target=price; Author=Max Michael]
X:= expression("Expression");
Len:=input("Length",6,3,10);
L3:=X*.5000+ref(X,-1)*.3333+ref(X,-2)*.1666;
L4:=X*.3143+ref(X,-1)*.3428+ref(X,-2)*.2286+ref(X,-3)*.1143;
L5:=X*.2063+ref(X,-1)*.3175+ref(X,-2)*.2381+ref(X,-3)*.1587+ref(X,-4)*.0797;
L6:=X*.1428+ref(X,-1)*.2857+ref(X,-2)*.2285+ref(X,-3)*.1714+ref(X,-4)*.1143+ref(X,-5)*.0571;
L7:=X*.1090+ref(X,-1)*.2179+ref(X,-2)*.2243+ref(X,-3)*.1795+ref(X,-4)*.1346+ref(X,-5)*.0897+ref(X,-6)*.0448;
L8:=X*.0844+ref(X,-1)*.1688+ref(X,-2)*.2132+ref(X,-3)*.1778+ref(X,-4)*.1422+ref(X,-5)*.1066+ref(X,-6)*.0711+ref(X,-7)*.0355;
L9:=X*.0666+ref(X,-1)*.1333+ref(X,-2)*.2000+ref(X,-3)*.1714+ref(X,-4)*.1428+ref(X,-5)*.1142+ref(X,-6)*.0857+ref(X,-7)*.0571+ref(X,-8)*.0286;
L10:=X*.0550+ref(X,-1)*.1100+ref(X,-2)*.1650+ref(X,-3)*.1674+ref(X,-4)*.1435+ref(X,-5)*.1196+ref(X,-6)*.0957+ref(X,-7)*.0717+ref(X,-8)*.0478+ref(X,-9)*.0239;
if(Len=3,L3,if(Len=4,L4,if(Len=5,L5,if(Len=6,L6,if(Len=7,L7,if(Len=8,L8,if(Len=9,L9,if(Len=10,L10,undefined))))))));




Edited by maximo - 11 Feb 2018 at 11:28am
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Bulletin Board Software by Web Wiz Forums® version 9.69
Copyright ©2001-2010 Web Wiz