Rank: Advanced Member
Groups: Moderators, Registered, Registered Users, Subscribers Joined: 10/8/2010(UTC) Posts: 1,960
Thanks: 92 times Was thanked: 155 time(s) in 150 post(s)
|
Ken Calhoun's recent article, “ATR Breakout Entries”, explained a high-volatility breakout trading system. The formulas below are some ways to employ this strategy in MetaStock: Exploration for new setups: This exploration will return just those instruments giving new setup signals. It lists the current closing price and the target entry price. "W R B" signifies the setup signal was a wide range bar. "Inc Vol" shows if the volume was increasing on the setup bar. Both of these are additional confirmation signals. They are not required for the setup. Column A:
Column Name: Close
Formula:
Column B:
Column Name: W R B
Formula:
Code:H-L > Ref(1.5 * HHV(H-L, 5), -1)
Column C:
Column Name: Inc Vol
Formula:
Column D:
Column Name: target
Formula:
Filter:
Formula:
Code:LLV(V, 90) >= 1000000 AND H-L >= 5 AND Cross(C, Mov(C,100,S)) AND ATR(14) > Ref(HHV(ATR(14), 14), -1) AND LLV(C, 90) >= 15 AND HHV(C, 90) <= 70
Expert Advisor:
The only exit specified in the article was an initial/trailing stop of $2. If you wish to see the setup, entry and exit signals on a chart, you can put these formulas in an expert advisor:
Setup:
symbol: diamond
formula:
Code:LLV(V, 90) >= 1000000 AND H-L >= 5 AND Cross(C, Mov(C,100,S)) AND ATR(14) > Ref(HHV(ATR(14), 14), -1) AND LLV(C, 90) >= 15 AND HHV(C, 90) <= 70
Buy signal:
symbol: up arrow
formula:
Code:stop:= 2;
setup:= LLV(V, 90) >= 1000000 AND H-L >= 5 AND Cross(C, Mov(C,100,S)) AND ATR(14) > Ref(HHV(ATR(14), 14), -1) AND LLV(C, 90) >= 15 AND HHV(C, 90) <= 70;
target:= ValueWhen(1, setup, H+0.5);
el:= H >= target;
eprice:= If(OPEN > target, OPEN, target);
trade:= If( PREV<=0, If(el, eprice-stop, 0),
If(L < PREV, -1, PREV));
trade > 0 AND Ref(trade <=0, -1)
Exit signal:
symbol: stop sign
formula:
Code:stop:= 2;
setup:= LLV(V, 90) >= 1000000 AND H-L >= 5 AND Cross(C, Mov(C,100,S)) AND ATR(14) > Ref(HHV(ATR(14), 14), -1) AND LLV(C, 90) >= 15 AND HHV(C, 90) <= 70;
target:= ValueWhen(1, setup, H+0.5);
el:= H >= target;
eprice:= If(OPEN > target, OPEN, target);
trade:= If( PREV<=0, If(el, eprice-stop, 0),
If(L < PREV, -1, PREV));
trade = -1
|