logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
minnamor  
#1 Posted : Wednesday, February 28, 2007 10:09:13 AM(UTC)
minnamor

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 126
Location: Italy

I have been trying to code the system called "Delphic Phenomenon" described in the book "Magic of Moving Averages" by Scott Lowry. For those not familiar with the system (very similar to Landry's Bow Tie), here is the description of the long and close long setups:
Long entry:
1) 18D SMA crosses above 40D SMA, then
2) Close rises above 18D SMA, then
3) Close drops below 18D SMA ( can go below 40D SMA), then
4) place a stop order at 18D SMA as long as 18D SMA > 40D SMA;
Long exit:
1) stop loss at 40D SMA, and
2) after 5 bars stop raised between 18D SMA and 40D SMA.

I have coded the following (Close instead of stop order assumed for next day entry at market open)

ma18:=Mov(C,18,S);
ma40:=Mov(C,40,S);
buy:=ma18>ma40 AND C<ma18;
sell:=ma18<ma40 AND C>ma18;
I:=Cum(Buy + Sell > -1) = 1;
Tr:=If(BarsSince(Buy OR I) < BarsSince(Sell OR I),1,-1);

LE:= Tr=1 AND C>ma18;
SE:= Tr=-1 AND C<ma18;
LX:= If(barssince(LE)<=5,C<ma40,C<ma18);
SX:= If(barssince(LE)<=5,C>ma40,C>ma18);
(latch omitted)

When plotted on charts, the system seems to give the appropriate entries and exits but maybe somebody may care to comment on the above code.
Thanks and regards.

Maurizio

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.