ADVANCED Strategies
ADVANCED Strategies
ADVANCED Strategies
B
{Strategy: #MultiBarRangeBO}
reakout systems are popular when markets are
Input: n(45),bx(0.45),m(15),sx(0.45),XTime(1515);
volatile. Such systems typically identify support
vars: hhv1(h),llv1(l),hhv2(h),llv2(l),ii(0),xb(c),xs(c);
and resistance levels when price has been moving
in a range or channel, and enter trades when price
hhv1=h; llv1=l;
breaks out of either the up side or down side of a channel.
for ii=1 to n-1 begin
There are two simple ways to define support and resistance
if h[ii]>hhv1 then hhv1=h[ii]; if l[ii]<llv1 then llv1=l[ii];
levels for price channels. In both cases, it is first necessary to
end;
define a lookback period. The first way is to use the highest
value1=hhv1-llv1;
high and the lowest low of the lookback period. The second
way is to determine the range of each bar (high minus low) and
hhv2=h; llv2=l;
add that range (or a percentage of it) to, or subtract it from, the
for ii=1 to m-1 begin
current close.
if h[ii]>hhv2 then hhv2=h[ii]; if l[ii]<llv2 then llv2=l[ii];
In either case, the upper and lower boundaries represent the
end;
price channel. One advantage to the second method is it better
value2=hhv2-llv2;
reflects the volatility of the market — it will expand and con-
tract as the volatility changes.
xb= c + (Value1 * bx);
Breakout strategies require the market to be in a high-volatil-
xs= c - (Value2 * sx);
ity period; a trade will become profitable only if it continues to
move in the direction of the breakout. Volatility and emotion go
if time<XTime then begin
hand in hand. As volatility increases, traders have to cope with
if marketposition<=0 then Buy Next Bar xb stop;
more risk; hence, the more emotional the market becomes. This
if marketposition>=0 then Sell Short Next Bar xs stop;
is often reflected by the fact markets fall faster than they rise.
end;
In the following system, the channel is determined by using
the range of the price bars in the lookback period. A breakout
if XTime<>0 then SetExitOnClose;
above or below the channel’s resistance or support creates buy
or sell signals.
Short
Short 1,005
Buy 1,000
995
990
Buy Short
End 985
End of day
of day exit
exit 980
600
400
200
0
-200
7/30 9:11 9:33 9:55 10:17 10:39 11:01 11:23 11:45 12:07 12:29 12:51 13:13 13:35 13:57 14:19 14:41 8/1
Source: TradeStation
that quickly reverse and stop out the position. With this sys- difficult to sustain more than a handful of consecutive losses,
tem, if there is a gap on the opening bar, the buy and sell ranges we eliminated all cases that had more than five losing trades in
are expanded and no trades are made until the buy and sell a row. Of the remaining test results, we chose the one that had
ranges contract or the price breaks the expanded ranges. the highest total net profit and the lowest drawdown. The opti-
Breaking the expanded ranges takes time and avoids the open- mization procedure produced the following system parame-
ing gap whipsaw. ters:
Testing n = 45;
The system was tested from July 7 through Aug. 1, 2003, using bx = 0.45;
September 2003 E-Mini futures (ESU03) one-minute bars. A m = 15;
wide range of parameter values was tested to find the optimal sx = 0.45;
ones for the system. The parameter ranges tested for the initial
optimization test were: Table 1 (p. 43) shows the performance summary for the four-
week test period (slippage and commissions not included).
n =10 to 50 in steps of 5; Table 2 (opposite page) is a trade-by-trade summary of all the
bx = 0.4 to 1 in steps of 0.05; trades. The average net profit per trade was $89 — well above
m = 10 to 50 in steps of 5; slippage and commissions for a typical S&P E-Mini trade. The
sx = 0.4 to 1 in steps of 0.05; largest losing trade was $300, and the biggest intraday draw-
down was $887. These losses are small compared to the total
After the initial test, we had to choose one set of parameters net profit of $4,912.
that produced the most realistic results. To avoid curve fitting, Figures 2 and 3 are one-minute charts of the S&P E-Mini
we eliminated all results that had profit factors (gross profit that span July 31 to Aug. 1. The Multibar Range Breakout chan-
divided by gross loss) greater than 4.0, since such performance nels are superimposed on the price series, and all the buy and
was unlikely to be duplicated in the future. Also, because it is sell signals are marked. Finally, the bottoms of Figures 2 and 3
600
400
200
14:19 14:41 8/1 9:02 9:24 9:46 10:08 10:30 10:52 11:14 11:36 11:58 12:20 12:42 13:04 13:26 13:48 14:10 14:32 14:54
Source: TradeStation
975
Individual articles can be purchased and
7 14 21 28
downloaded from www.activetradermag.com/
purchase_articles.htm. Source: TradeStation
EQUITY CURVE
600,000
DeMark variation
500,000
Markets: Stocks, stock index futures, index stocks
(SPDRs, DIAs, QQQs), futures and currencies
400,000
Disclaimer: The Trading System Lab is intended for educational purposes only to provide a perspective on different market concepts. It is not meant to recommend or
promote any trading system or approach. Traders are advised to do their own research and testing to determine the validity of a trading idea. Past performance does not
guarantee future results; historical testing may not reflect a system’s behavior in real-time trading.