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 : Friday, February 9, 2007 11:15:07 AM(UTC)
minnamor

Rank: Advanced Member

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

Chuck Lebeau in his Traders Club Bulletin N. 47 describes the ATR Ratchet Stop (http://traderclub.com/discus/messages/107/1501.html?SaturdayJuly2120010131pm).
He gives the following description of the logic:
"Here is an example of the strategy: After the trade has reached a profit target of at least one ATR or more, we pick a recent low point (such as the lowest low of the last ten days). Then we add some small daily unit of ATR (0.05 ATR for example) to that low point for each day in the trade. If we have been in the trade for 15 days we would multiply 0.05 ATRs by 15 days and add the resulting 0.75 ATRs to the starting point. After 20 days in the trade we would now be adding 1.0 ATRs (.05 times 20) to the lowest low of the last ten days."
He suggests waiting to use the exit until some minimum level of profitability has been reached because this stop has a way of moving up very rapidly under favorable market conditions.
"One of the nice features about the ATR Ratchet is that we can start it any place we want. For example we can start it at some significant low point just as the Parabolic does. Or we can start it at a swing low, a support level, and a channel low or at our entry point minus some ATR unit. If we wait until the trade is fairly profitable we could start it at the entry point or even somewhere above our entry point."
This represents a first attemp at writing the ATR Ratchet.

Buy:= Cross(Mov(C,10,E),Mov(C,20,E)) ;
Sell:= Cross(Mov(C,20,E),Mov(C,10,E)) ;
I:=Cum(Buy + Sell > -1) = 1;
Tr:=If(BarsSince(Buy OR I) < BarsSince(Sell OR I),1,-1);

acc:=Input("Acceleration Factor in Percent",.01,.10,.02);
brs:=Input("Lookback periods",1,100,10);
acf1:=(acc)*BarsSince(Buy);
acf2:=(acc)*BarsSince(Sell);
val1:=LLV(L,brs)+acf1*ATR(14);
val2:=HHV(H,brs)-acf2*ATR(14);
rat:=If(Tr=1,val1,val2);
rat;

Any suggestions on improving the above formula would be appreciated.
Thank and regards.

Maurizio

wabbit  
#2 Posted : Friday, February 16, 2007 5:54:09 AM(UTC)
wabbit

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)
Hi Maurizio,

I actually haven't run your code as I am still updating all of my data from a long holiday overseas, but I would like to make one comment about your latch code...

In this instance, your latching system will work because you have a criteria for the entry and its anti-criteria for the exit. You should be careful that in the instance when you have an entry criteria and an exit criteria independent of the entry as it might be possible for your trailing stop to be moving unexpectedly DURING the trade.

You might want to have a look at some of the many posts in this forum regarding latches and consider using a PREV or two to refer to the exact instance when the trade was entered, or stick a comment in the top of the code to remind yourself about the limits of the function, just so you don't forget if you use other entry and exit systems.

Hope this helps.

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.