Rank:: Advanced Member
Groups: Registered, Registered Users Joined: 2/19/2012(UTC) Posts: 106
Thanks: 1 times Was thanked: 1 time(s) in 1 post(s)
|
The MSFL for cyber cycles with and without inverse Fisher transform is posted on https://www.metastock.co.../TASC/Article.aspx?Id=60
The Cyber Cycle plot does not show any trigger line as described by Ehlers.
The one with the transform shows debugging errors and/if plotted gives error messages. Can anybody help?
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
Try : http://www.traders.com/Documentation/FEEDbk_docs/2004/05/TradersTips/TradersTips.html>or Code:
pr:=(H+L)/2;
a:=0.07;
sp:=(pr+(2*Ref(pr,-1))+(2*Ref(pr,-2))+Ref(pr,-3))/6;
cycle:=Power(1-(.5*a),2)*(sp-(2*Ref(sp,-1))+Ref(sp,-2))+(2*(1-a))*PREV-(Power(1-a,2)*Ref(PREV,-1));
ft:=(Exp(2*cycle)-1)/(Exp(2*cycle)+1);
{plot}
.5;
-.5;
ft;
but this code doesn't include any error trapping, so watchout for DBZ and overflow errors! wabbit [:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
Wabbit -- Tried on SPX, get an OVERFLOW error right off the bat...
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
JJ,
The largest value input for Exp() is 88.722835540, so normalise the cycle parameter to half this value (it gets doubled again in the IFT)
wabbit [:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
Code:
pr:=(H+L)/2;
a:=0.07;
sp:=(pr+(2*Ref(pr,-1))+(2*Ref(pr,-2))+Ref(pr,-3))/6;
cycle:=Power(1-(.5*a),2)*(sp-(2*Ref(sp,-1))+Ref(sp,-2))+(2*(1-a))*PREV-(Power(1-a,2)*Ref(PREV,-1));
limit:=88.722835540 / 2;
{normalise [-1,1], no allowance for sgn(range)? }
cycle:=(2*(cycle-lowest(cycle))/max(highest(cycle)-lowest(cycle),power(10,-8)))-1;
{normalise [-limit,limit]}
cycle:=limit*cycle;
ft:=(Exp(2*cycle)-1)/(Exp(2*cycle)+1);
{plot}
.5;
-.5;
ft;
wabbit [:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
wabbit wrote:The largest value input for Exp() is 88.722835540
How blue bloody blazes did you find out that limit, might I ask?
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
I guess I should add that, as the normalisation compression is non-linear, you cannot simply use the +/- 0.5 levels without due consideration.
wabbit [:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
Curve doesn't quite seem the same:
Code:
pr:= (H+L)/2;
a:= 0.07;
sp:= (pr+(2*Ref(pr,-1))+(2*Ref(pr,-2))+Ref(pr,-3))/6;
cycle:=Power(1-(.5*a),2)*(sp-(2*Ref(sp,-1))+Ref(sp,-2))+(2*(1-a))*PREV-(Power(1-a,2)*Ref(PREV,-1));
.5;
-.5;
(Exp(2*cycle)-1)/(Exp(2*cycle)+1);
Code:
pr:=(H+L)/2;
a:=0.07;
sp:=(pr+(2*Ref(pr,-1))+(2*Ref(pr,-2))+Ref(pr,-3))/6;
cycle:=Power(1-(.5*a),2)*(sp-(2*Ref(sp,-1))+Ref(sp,-2))+(2*(1-a))*PREV-(Power(1-a,2)*Ref(PREV,-1));
limit:=88.722835540 / 2;
{normalise [-1,1], no allowance for sgn(range)? }
cycle:=(2*(cycle-lowest(cycle))/max(highest(cycle)-lowest(cycle),power(10,-8)))-1;
{normalise [-limit,limit]}
cycle:=limit*cycle;
ft:=(Exp(2*cycle)-1)/(Exp(2*cycle)+1);
{plot}
.5;
-.5;
ft;
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
As I said, the compression is non-linear so any levels (0, 0.5 etc) are just arbitrary, so to reinstate those levels to have the plot "make sense" you have to know where the levels get mapped to and then make that correction.
Of course, this entire problem goes away by utilising customised ExtFml() outside of the limitations of MS.
wabbit[:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
Just for fun, here's a compression system in lieu of normalising the cycle: Code:
pr:=(H+L)/2;
a:=0.07;
sp:=(pr+(2*Ref(pr,-1))+(2*Ref(pr,-2))+Ref(pr,-3))/6;
cycle:=Power(1-(.5*a),2)*(sp-(2*Ref(sp,-1))+Ref(sp,-2))+(2*(1-a))*PREV-(Power(1-a,2)*Ref(PREV,-1));
limit:=88.722835540 / 2;
{compression: cycle -> [-1,1] -> [-limit,limit], 0 -> 0}
cycle:=limit*cycle/Max(Highest(Abs(cycle)),Power(10,-8));
ift:=(Exp(2*cycle)-1)/(Exp(2*cycle)+1);
{plot}
ift;
wabbit [:D]
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
wabbit wrote:Of course, this entire problem goes away by utilising customised ExtFml() outside of the limitations of MS.
I presume you mean a DLL using higher precision internals?
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
Yes, and internal error handling for arguments out of bounds.
wabbit [:D]
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.