, Pardo Robert The Evaluation And Optimization Of Trading Strategies, Second Edition 

[ Pobierz całość w formacie PDF ]
.This can result in a windfall profit or lossin the simulation, when, in fact, that situation never existed in real trading.If the strategist chooses to use the continuous contract for testing, this rollgap must be taken into consideration.THE PERPETUAL CONTRACTAnother popular solution is the perpetual contract.This contract is verydifferent from the continuous contract.It consists of a mathematical trans-formation of price data which are, consequently, not real price data.Price c06 JWPR070-Pardo December 18, 2007 14:17 Char Count=The Historical Simulation 125data in a perpetual contract are actually created with an interpolation for-mula that attempts to create the three-month forward values of the com-modity in a manner similar to the London Metals Exchange forward pric-ing.The design of the extrapolation formula is intended to create a pricehistory that is close to the targeted three-month contract.The perpetual contract solves two of the three major problems: It canbe as long as necessary and it eliminates the rollover price gaps.Whereasits price and volatility structure is similar to that of the front contract pricedata, it is not exactly like the actual prices of the front contract that itattempts to model.This difference will introduce subtle discrepancies be-tween simulated performance and real-time trading performance.The perpetual contract introduces three unique problems.First, itdoes not contain real price history.Every price is transformed.Second,it introduces a new distortion of its own and it tends to somewhat ar-tificially dampen actual price volatility by behaving differently from theactual price data themselves.Third, entry orders for real-time trading de-rived from it must be transformed.If used to create daily trading signals,these signal prices will need to be adjusted so as to be usable in real-timetrading.This added price distortion may be of little consequence, with a veryslow system that trades for the big moves.This distortion, however, mayprove to be a serious problem with a very active trading system that targetssmall moves and is highly sensitive to short-term changes in volatility.ADJUSTED CONTINUOUS CONTRACTSThe adjusted continuous contract combines the best of all of the precedingalternatives.It merges front expiration price data into a continuous pricehistory.It mathematically removes all of the price roll gaps, however.It canbe done in two ways.Contracts can be adjusted, keeping the most recentdata unchanged and adjusting all preceding data up or down an amountequal to the roll gaps.This is a back-adjusted continuous contract (seeFigure 6.4).A front-adjusted continuous contract adjusts from the beginning of thefile to the end.This leaves the most distant data in their natural form andthe most current data are adjusted.The neutral data transform preserves the relative differences betweenprices.It introduces a distortion with any calculations that use percentagesof price.It cannot be used with charting applications that use absoluteprices for support and resistance.Back-adjusted contracts can also havenegative prices because of the gap adjustments. c06 JWPR070-Pardo December 18, 2007 14:17 Char Count=126 THE EVALUATION AND OPTIMIZATION OF TRADING STRATEGIESFIGURE 6.4 S&P Futures Continuous Back-Adjusted ContractA back-adjusted continuous contract solves all three of the major prob-lems for most systems: It can be as long as necessary, it faithfully repre-sents the data to be traded, and it eliminates the rollover gap.If the pricedata extend far back in time, prices can become unusually large or evennegative, which will introduce a distortion in calculations using a percent-age of price.Back-adjusted continuous contracts, therefore, are not with-out problems testing some types of trading strategies.THESIZEOFTHETEST 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 1/1/1995 through 12/31/2006.Definition: The test window is the length of the historical price data onwhich a trading strategy is evaluated by historical simulation. c06 JWPR070-Pardo December 18, 2007 14:17 Char Count=The Historical Simulation 127Two main considerations must be satisfied when deciding the size ofthe test window: statistical soundness and relevance to the trading systemand to the market.These two requirements do not stipulate the size of a particular testwindow in days, weeks, or months.Instead, they specify a set of guidelinesthat can be followed to determine the correct window size for a particulartrading strategy and market.One size does not fit all when it comes to sizeof the test window.The size of the test window will have a significant impact upon theoutcome and reliability of the historical simulation.Its size will influenceparameter selection and trading pace.It will also go a long way towarddetermining the statistical reliability, or lack thereof, of the simulation.Statistical RequirementsThe test window must be large enough to generate statistically sound re-sults and also include a broad sample of data conditions.Statisticallysound means two things.There must be a sufficiently large number oftrades so as to be able to draw meaningful conclusions.The test win-dow must also be large enough to allow enough degrees of freedom forthe number and length of the variables employed by the trading strategy.If these guidelines are not followed, the results of the historical simula-tion are likely to be deficient in statistical robustness, and are thereforesuspect.Sample Size and Statistical ErrorThe standard error is a mathematical concept used in statistical analysis.We can use an application of this statistic to provide us with some help-ful insight regarding the impact of the trade sample size produced by ourhistorical simulation on the robustness and precision of the resulting per-formance statistics.A large standard error would indicate that the datapoints are far from the average and a small standard error indicates thatthey are clustered closely around the average.The smaller the standarderror the less an individual winning trade will vary from the average win-ning trade.Standard Error = Standard Deviation/Square Root of the Sample SizeWe are going to calculate three standard errors of the average winningtrade based on three different numbers of winning trades. c06 JWPR070-Pardo December 18, 2007 14:17 Char Count=128 THE EVALUATION AND OPTIMIZATION OF TRADING STRATEGIESLet us specify the values to be used in our application of this formulato calculate the standard error of the mean or average win:AWt = Average WinStDev = Standard DeviationSqRt = Square RootNwt = Number of Winning TradesStandardError = StDev(AWt)/SqRt(Nwt)Standard error will provide us a measure of reliability of our averagewin as a function of the number of winning trades, that is, the sample size.For example, if the average win is $200 and has a standard error of $50,then the typical win will be within a range of $150 to $250 ($200 +/ $50 [ Pobierz całość w formacie PDF ]
  • zanotowane.pl
  • doc.pisz.pl
  • pdf.pisz.pl
  • anikol.xlx.pl