Size of Test Window

Embed Size (px)

Citation preview

  • 8/9/2019 Size of Test Window

    1/2

    THE SIZE OF THE TEST WINDOWA simulation of a trading strategy is performed on a segment of historicaldata of some length or another. For example, a historical simulation of amoving average system is constructed on S&P 500 futures historical pricedata from 111!!5 through 1"#1"00$.%enition' (he test window is the length of the historical price data on

    )hich a trading strategy is evaluated *y historical simulation. ()o main considerations must *e satised )hen deciding the si+e of the test )indo)' statistical soundness and relevance to the trading systemand to the maret.

     (hese t)o re-uirements do not stipulate the si+e of a particular test)indo) in days, )ees, or months. nstead, they specify a set of guidelinesthat can *e follo)ed to determine the correct )indo) si+e for a particulartrading strategy and maret. /ne si+e does not t all )hen it comes to si+eof the test )indo).

     (he si+e of the test )indo) )ill have a signicant impact upon theoutcome and relia*ility of the historical simulation. ts si+e )ill inuenceparameter selection and trading pace. t )ill also go a long )ay to)arddetermining the statistical relia*ility, or lac thereof, of the simulation.

    Statistical Requirements (he test )indo) must *e large enough to generate statistically sound resultsand also include a *road sample of data conditions. Statistically sound means t)o things. (here must *e a suciently large num*er of trades so as to *e a*le to dra) meaningful conclusions. (he test )indo)must also *e large enough to allo) enough degrees of freedom forthe num*er and length of the varia*les employed *y the trading strategy.f these guidelines are not follo)ed, the results of the historical simulationare liely to *e decient in statistical ro*ustness, and are thereforesuspect.

    Sample Size and Statistical Error (he standard error is a mathematical concept used in statistical analysis.2e can use an application of this statistic to provide us )ith some helpful

    insight regarding the impact of the trade sample si+e produced *y ourhistorical simulation on the ro*ustness and precision of the resulting performancestatistics. A large standard error )ould indicate that the datapoints are far from the average and a small standard error indicates thatthey are clustered closely around the average. (he smaller the standarderror the less an individual )inning trade )ill vary from the average )inningtrade.Standard 3rror 4 Standard %eviation / S-uare oot of the Sample Si+e2e are going to calculate three standard errors of the average )inningtrade *ased on three di6erent num*ers of )inning trades.7et us specify the values to *e used in our application of this formulato calculate the standard error of the mean or average )in'A2t 4 Average 2inSt%ev 4 Standard %eviationS-t 4 S-uare oot8)t 4 8um*er of 2inning (radesStandard3rror 4 St%ev9A2t: / S-t98)t:Standard error )ill provide us a measure of relia*ility of our average)in as a function of the num*er of )inning trades, that is, the sample si+e.For example, if the average )in is ;"00 and has a standard error of ;50,then the typical )in )ill *e )ithin a range of ;150 to ;"50 9;"00

  • 8/9/2019 Size of Test Window

    2/2

    range of expected )ins:. (o get an idea of ho) this plays out )ith di6erent sample si+es, considerthree examples of standard error *ased on di6erent trade samplesi+es of 10, #0, and 100. 2e )ill assume a standard deviation for our )inningtrades of ;100.2hen our num*er of )ins is 10, the standard error is'

    Standard 3rror 4 100 / S-t910:Standard 3rror 4 100 / #.1$Standard 3rror 4 #1.$52ith a sample of 10 trades, the standard error is #1.$5 rounded to;#". Plugging this value into our formula, the range of )ins is ;"00