SP trend following System

Discussion in 'Strategy Building' started by acrary, Oct 14, 2002.

  1. acrary

    acrary

    Most traders are familiar with the concept of trend following. If you're looking for a system in the SP or emini market, here's something to start with.

    NOTE: This is based on the character of the sp market. It has no EDGE, so it could fall apart at anytime.

    Overall rules:

    1). Risk 2% of portfolio per-trade.
    2). Only initiate trades when the 14 period ADX is less than 25.
    3). Use 30 min. bars.

    Entry Rules:

    1). Buy at the highest high for the past 15 bars.
    2). Sell at the lowest low for the past 15 bars.

    Exit Rules:

    1). Exit long trades at the lowest low for the past 5 bars.
    2). Exit short trades at the highest high for the past 5 bars.

    It's made money every year since 1990 and has had a max. peak-valley drawdown of 19% in 1996. So far this year it's up about 70k on a single contract basis.

    Here's the 11 year results from 1990 - 2000 using continuous intraday data. The starting portfolio size was 150k and risk per-trade was limited to 2%. I don't have 2001 and 2002 folded into the continuous contracts, so I had to test them separately. Both years were profitable.
     
    baggs likes this.
  2. This system that you have thrown out has character but no edge. Hmmmm....

    That means that the next step is to incoporate filters and screens?
     
  3. acrary

    acrary

    Hi reverend,

    I suppose you could put in some filters and such.
    I got some PM from people that were having trouble finding anything to trade, so I decided to post this simple system. Sometimes it's easier to modify something than to find a starting point.

    FWIW, I tried a filter of only taking the trades in the same direction of a longer term trend (40 bars moving ave. had to be higher than 16 bar moving ave. to go long, etc.). It improved the profit factor, but hurt the overall profitability. The problem with all trend following systems is when you become selective, you often miss some of the big moves.

    My analysis of why this method works is that the distribution of trades is not normal. Experienced traders know the markets have fatter tails than a normal distribution. This simple system catches the big tail moves, while breaking even on all the chop slop.
     
  4. Kaizen

    Kaizen

  5. acrary, could you please elaborate on the difference between a system profitting off "market character" and one having an #@E-D-G-E@# ?? By the way, I read something like that posted on TraderClub Forum, was it you by any chance (emini daytrading thread)?
     
  6. acrary - is that buy on a BREAK of the highest high of the past 15 bars or just at the high of the past 15 bars?

    Same question on the stops.

    Did you test using a breakout of the 15 bar price channel or just a touch of the channel?
     
  7. net profit in 2000 = $727,920.00
    net profit in 1999 = $548,925.00
    with how many contracts?


    -1). Risk 2% of portfolio per-trade-

    acrary, how big would you say, should the portfolio be right now, if one wants to start with 1 contract?
     
  8. alain

    alain

    I know there are Snowbaord, Skateboard, Bike, Inline etc... Extreme Movies.

    But I didn't know that there are such Extreme Movies about trading.... :p
     
  9. wdbaker

    wdbaker

    All,
    I ran a backtest for this, looks pretty good to me, when you see B&H that is reference to Buy & Hold. This was tested on e-mini S&P 1 1/2 years data, starting with $5000 and subtracting $30 dollars per RT for slippage and commissions. 1 contract only and margin set at $2500. I will post the equity curve next.

    See Below(read: Scroll Down)
    wdbaker

    <HEAD>
    <TITLE>AmiBroker System Test Report</TITLE><STYLE>
    <!--
    BODY { font-family:"Tahoma,Arial,Helvetica,Sans Serif"; font-size:8pt; }
    TD { font-size:8pt; text-align: right; }
    TH { font-size:8pt; text-align: left; font-weight:normal; }
    .BIG { font-size:10pt; font-weight:bold; text-align: center; }
    -->
    </STYLE></HEAD>
    <BODY>
    <TABLE CELLSPACING=2 WIDTH=100%>
    <TR bgcolor="#CCCCCC"><TH COLSPAN=5 CLASS="BIG" >Settings</TH></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Initial Equity:</TH><TD>5000</TD><TD></TD><TH>Periodicity/Positions:</TD><TD>30 minute/Long Short</TD></TR>
    <TR><TH>Commissions:</TH><TD>15.00 per share</TD><TD></TD><TH>Annual interest rate:</TH><TD>0.00%</TD></TR>
    <TR><TH>Range:</TH><TD>All quotations</TD><TD></TD><TH>Apply to:</TH><TD>Current Symbol</TD></TR><TR><TH>Margin requirement:</TH><TD>100</TD><TD></TD><TH>Futures mode:</TH><TD>Yes</TD></TR>
    <TR><TH>Def. round lot size:</TH><TD>1</TD><TD></TD><TH>Def. Tick Size</TH><TD>0.25</TD></TR>
    <TR><TH>Drawdowns based on:</TH><TD>High/Low prices</TD><TD></TD><TH>&nbsp;</TH><TD>&nbsp;</TD></TR>
    <TR><TH COLSPAN=5><b>Long trades</b></TH></TR>
    <TR><TH>Buy price:</TH><TD>Close</TD><TD></TD><TH>Sell price:</TD><TD>Close</TD></TR>
    <TR><TH>Buy delay:</TH><TD>0</TD><TD></TD><TH>Sell delay:</TD><TD>0</TD></TR>
    <TR><TH COLSPAN=5><b>Short trades</b></TH></TR>
    <TR><TH>Short price:</TH><TD>Close</TD><TD></TD><TH>Cover price:</TD><TD>Close</TD></TR>
    <TR><TH>Short delay:</TH><TD>0</TD><TD></TD><TH>Cover delay:</TD><TD>0</TD></TR>
    <TR><TH COLSPAN=5><b>Stops</b></TH></TR>
    <TR><TH>Maximum loss:</TH><TD>disabled</TD><TD></TD><TH>Profit target:</TD><TD>disabled</TD></TR>
    <TR><TH>Value:</TH><TD>0.00</TD><TD></TD><TH>Value:</TD><TD>0.00</TD></TR>
    <TR><TH>Exit at stop?</TH><TD>no</TD><TD></TD><TH>Exit at stop?</TD><TD>no</TD></TR>
    <TR><TD colspan=5>&nbsp;</TD></TR><TR><TH>Trailing stop:</TH><TD>disabled</TD><TD></TD><TH>&nbsp;</TD><TD>&nbsp;</TD></TR>
    <TR><TH>Value:</TH><TD>0.00</TD><TD></TD><TH>&nbsp;</TD><TD>&nbsp;</TD></TR>
    <TR><TH>Exit at stop?</TH><TD>no</TD><TD></TD><TH>&nbsp;</TD><TD>&nbsp;</TD></TR>
    </TABLE><P><TABLE CELLSPACING=2 WIDTH=100%>
    <TR bgcolor="#CCCCCC"><TH COLSPAN=5 CLASS="BIG" >Formula</TH></TR>
    </TABLE><PRE>
    Filter=TimeNum()&gt;=080000 AND TimeNum()&lt;=150000;
    PositionSize=2500;

    test1=ADX(14)&lt;25 AND Close&gt;Ref(HHV(Close,15),-1);
    test2=ADX(14)&lt;25 AND Close&lt;Ref(LLV(Close,15),-1);

    //*Buy___________________________________*//

    Buy=test1 ;
    Sell=Close&lt;Ref(LLV(Close,5),-1);

    //*Sell___________________________________*//

    Short=test2 ;
    Cover=Close&gt;Ref(HHV(Close,5),-1);
    </PRE><TABLE CELLSPACING=2 WIDTH=100%>
    <TR bgcolor="#CCCCCC"><TH COLSPAN=5 class="BIG">Overall performance summary</TH></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Total net profit:</TH><TD>15955.00</TD><TD>&nbsp;</TD><TH>Total commissions paid:</TH><TD>7680.00</TD></TR>
    <TR><TH>Return on account:</TH><TD>319.10 %
    </TD><TD>&nbsp;</TD><TH>Open position gain/loss</TH><TD>7.50</TD></TR><TR><TH>Buy&Hold profit:</TH><TD>-17280.00</TD><TD>&nbsp;</TD><TH>Bars (avg. days) in test:</TH><TD>5642 (553)</TD></TR>
    <TR><TH>Buy&Hold % return:</TH><TD>-345.60%</TD><TD>&nbsp;</TD><TH>System to Buy&Hold index:</TH><TD>192.33%</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Annual system % return:</TD><TD>157.49%</TD><TD>&nbsp;</TD><TH>Annual B&H % return:</TH><TD> N/A </TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>System drawdown:</TH><TD>-2470.00</TD><TD>&nbsp;</TD><TH>B&H drawdown:</TH><TD>-21350.00</TD></TR>
    <TR><TH>Max. system drawdown:</TH><TD>-5715.00</TD><TD>&nbsp;</TD><TH>B&H max. drawdown:</TH><TD>-23687.50</TD></TR>
    <TR><TH>Max. system % drawdown:</TH><TD>-50.87%</TD><TD>&nbsp;</TD><TH>B&H max. % drawdown:</TH><TD>-458.07%</TD></TR>
    <TR><TH>Max. trade drawdown:</TH><TD>-5500.00</TD><TD>&nbsp;</TD><TH>&nbsp;</TH><TD>&nbsp;</TD></TR>
    <TR><TH>Max. trade % drawdown:</TH><TD>-48.14%</TD><TD>&nbsp;</TD><TH>&nbsp;</TH><TD>&nbsp;</TD></TR>
    <TR><TH>Trade drawdown:</TH><TD>-1125.00</TD><TD>&nbsp;</TD><TH>&nbsp;</TH><TD>&nbsp;</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Total number of trades:</TH><TD>256</TD><TD>&nbsp;</TD><TH>Percent profitable:</TH><TD>42.6%</TD></TR>
    <TR><TH>Number winning trades:</TH><TD>109</TD><TD>&nbsp;</TD><TH>Number losing trades:</TH><TD>147</TD></TR>
    <TR><TH>Profit of winners:</TH><TD>63580.00</TD><TD>&nbsp;</TD><TH>Loss of losers:</TH><TD>-47647.50</TD></TR>
    <TR><TH>Total # of bars in winners:</TH><TD>1782</TD><TD>&nbsp;</TD><TH>Total # of bars in losers:</TH><TD>962</TD></TR>
    <TR><TH>Commissions paid in winners:</TH><TD>3270.00</TD><TD>&nbsp;</TD><TH>Commissions paid in losers:</TH><TD>4410.00</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Largest winning trade:</TH><TD>2682.50</TD><TD>&nbsp;</TD><TH>Largest losing trade:</TH><TD>-955.00</TD></TR>
    <TR><TH># of bars in largest winner:</TH><TD>38</TD><TD>&nbsp;</TD><TH># bars in largest loser:</TH><TD>7</TD></TR>
    <TR><TH>Commission paid in largest winner:</TH><TD>30.00</TD><TD>&nbsp;</TD><TH>Commission paid in largest loser:</TH><TD>30.00</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Average winning trade:</TH><TD>583.30</TD><TD>&nbsp;</TD><TH>Average losing trade:</TH><TD>-324.13</TD></TR>
    <TR><TH>Avg. # of bars in winners:</TH><TD> 16.3</TD><TD>&nbsp;</TD><TH>Avg. # bars in losers:</TH><TD> 6.5</TD></TR>
    <TR><TH>Avg. commission paid in winner:</TH><TD>30.00</TD><TD>&nbsp;</TD><TH>Avg. commission paid in loser:</TH><TD>30.00</TD></TR>
    <TR><TH>Max consec. winners:</TH><TD>7</TD><TD>&nbsp;</TD><TH>Max consec. losers:</TH><TD>7</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Bars out of the market:</TH><TD>2913</TD><TD>&nbsp;</TD><TH>Interest earned:</TH><TD>0.00</TD></TR>
    <TR><TH COLSPAN=5>&nbsp;</TH></TR>
    <TR><TH>Exposure:</TH><TD>48.4%</TD><TD>&nbsp;</TD><TH>Risk adjusted ann. return:</TH><TD>325.59%</TD></TR>
    <TR><TH>Ratio avg win/avg loss:</TH><TD>1.80</TD><TD>&nbsp;</TD><TH>Avg. trade (win & loss):</TH><TD>62.24</TD></TR>
    <TR><TH>Profit factor:</TH><TD>1.33</TD><TD>&nbsp;</TD><TH></TH><TD></TD></TR></TABLE>
     
  10. wdbaker

    wdbaker

    Equity Curve
     
    #10     Oct 15, 2002