31.07.2021 Views

Ultimate Algorithmic Trading System

Using automated systems for trading in stock markets

Using automated systems for trading in stock markets

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

TABLE 8.3

In-Sample Testing TA2

Le Se Lx Sx Begin Date End Date Bars Profit Max DD

20 20 12 10 2001/09/18–2005/06/15 975 24, 843.75 −9, 187.50

20 20 12 10 2002/10/11–2006/07/07 975 28, 375.00 −9, 187.50

20 20 16 10 2003/09/05–2007/06/27 975 23, 687.50 −8, 093.75

20 24 12 12 2004/10/04–2008/06/26 975 6, 437.50 −8, 343.75

20 20 12 14 2005/08/16–2009/04/07 975 18, 531.25 −11, 906.25

20 36 10 14 2006/08/15–2010/06/04 975 11, 843.75 −13, 843.75

20 20 12 14 2007/09/20–2011/04/18 975 21, 531.25 −13, 187.50

20 24 12 14 2008/07/17–2012/04/06 975 22, 375.00 −17, 656.25

20 56 10 14 2009/06/23–2013/03/27 975 8, 250.00 −15, 375.00

24 24 12 14 2010/09/03–2014/04/04 975 18, 187.50 −17, 656.25

184, 062.50

Table 8.3 shows the best parameter sets over a four-year period carried one year

forward sequentially. Row 1 starts with September 2001 and ends on June 15,

2005. The best-performing parameters were selected over that time period and

displayed. Row 2 starts a year later in October 2002 and ends in July 2006, and

the best parameters are also shown. The process is continued through April 2014.

The results are spectacular, but beware of the benefit of hindsight. Notice how the

Le, Lx, and Sx parameters stayed somewhat consistent; this does demonstrate

parameter stability. The Se parameter was all over the map, and you can see that the

system did not want to sell short between June 2009 and March 2013; the sell entry

utilized a whopping 56 days in its calculation. Figure 8.6 is a graphic representation

of how the analysis rolls forward.

Out-Of-Sample Testing When you run a WFO, the software builds a database of

these ‘‘best’’ parameter sets and then informs the algorithm when to adopt and when

to abandon them. TradeStation’s WFO keeps track of all parameter switching and

performance metrics on the trading algorithm as it progresses through the history of

whatever you are testing.

The whole purpose of this software and this type of testing is based on the belief

of optimization overhang or carryover; if a parameter has done well for the past four

251

GENETIC OPTIMIZATION, WALK FORWARD

2001 2002 2003 2004

2002 2003 2004 2005

2003 2004 2005 2006

FIGURE 8.6

A graphic representation of how the walk-forward analysis (WFA) rolls forward.

www.rasabourse.com

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!