Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 10/29/2004(UTC) Posts: 1,394 Location: Glastonbury, CT
Was thanked: 2 time(s) in 2 post(s)
|
You will need the Power Pivots Plus Add-on for this Expert to work.
This is designed for a daily chart
Highlights
Long
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B>0
Short
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B<0
Out
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B=0
Symbols
Long Entry
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B>0 AND Ref(B,-1)<=0
Short entry
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B<0 AND Ref(B,-1)>=0
Long Exit
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B=0 AND Ref(B,-1)>0
Short exit
A1:= ExtFml("PowerPivots.TrendDirection",1,1);
A2:= ExtFml("PowerPivots.TrendDirection",1,2);
TD:=If(A1=1,1,If(A1=-1,-1,0))+If(A2=1,2,If(A2=-1,-2,0));
htfData:=ExtFml("PowerPivots.TDataCreate",3,2);
x:=Mov(htfData,10,S);
MA:=ExtFml("PowerPivots.TDataLocalize",x,2,0);
LE:=C>MA AND TD>0;
SE:=C<MA AND TD<0;
LX:=C<MA;
SX:=C>MA;
B:=ExtFml("PowerPivots.SysEval",LE,LX,SE,SX,"!@#$#@!");
B=0 AND Ref(B,-1)<0
|