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)
|
using the PowerPivots Plus Add-on Tirone Levels Code:
Piv:=Input("Pivot (1=Minor 2=Interm 3=Major 4=Primary)",1,4,2);
TF:=Input("TFactor",1,4,1);
PPs:= ExtFml("PowerPivots.Pivots");
TD:= ExtFml("PowerPivots.TrendDirection",Piv,TF);
TD:=If(Sum(TD=1,2)>1,1,If(Sum(TD=-1,2)>1,-1,0));
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,0);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.333);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.5);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.666);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,1);
ExtFml("PowerPivots.RetInd",1,PPs,TD,Piv,1);
ExtFml("PowerPivots.RetInd",2,PPs,TD,Piv,1);
this plots the last pivot levels This is for fib levels Code:
Piv:=Input("Pivot (1=Minor 2=Interm 3=Major 4=Primary)",1,4,2);
TF:=Input("TFactor",1,4,1);
PPs:= ExtFml("PowerPivots.Pivots");
TD:= ExtFml("PowerPivots.TrendDirection",Piv,TF);
TD:=If(Sum(TD=1,2)>1,1,If(Sum(TD=-1,2)>1,-1,0));
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,0);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.25);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.382);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.5);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,.618);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,1);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,1.382);
ExtFml("PowerPivots.RetInd",0,PPs,TD,Piv,1.618);
ExtFml("PowerPivots.RetInd",1,PPs,TD,Piv,1);
ExtFml("PowerPivots.RetInd",2,PPs,TD,Piv,1);
Using the Highest() and Lowest()functions Code:
HLevel:=Highest(H);
LLevel:=Lowest(L);
Range:=HLevel-LLevel;
Third:=LLevel+(Range*.33);
twoThird:=LLevel+(Range*.66);
Half:=LLevel+(Range*.5);
HLevel;twothird;Half;Third;LLevel;
Using the HHV and LLV functions Code:
Pds:=Input("lookback",10,100,20);
HLevel:=HHV(H,Pds);
LLevel:=LLV(L,Pds);
Range:=HLevel-LLevel;
Third:=LLevel+(Range*.33);
twoThird:=LLevel+(Range*.66);
Half:=LLevel+(Range*.5);
HLevel;twothird;Half;Third;LLevel;
|