Archive for the ‘Glossary’ Category

Glossary

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

The next 60 posts are a glossary of backtesting terms.   I wrote them in blog form, so each post has an associated creation date.    I may edit these definitions over time but will keep the initial dates so that the definitions stay in alphabetical order.

Active Investor Definition

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

I use the term Active Investor to identify people who manage their market positions.  An active investor not only investigates a stock before buying, but also considers when and why they might sell.   

This distinguishes the active investor from the passive investor.  The latter often simply invests in a market index, and whatever they buy, they set out to keep for the long term.   Hence the moniker “buy and hold”.

Extra Insight:

In an effort to match up to trader types in my backtesting, I estimated that an active investor sticks with a position for about a year.

Tags: ,

Adverse Excursion Definition

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

An Adverse Excursion is the amount that a trade goes in the wrong direction after entry and before exit.   The Maximum Adverse Excursion (MAE) is the worst over the life of the trade.

For example, say a stock is bought at $30, then drops to $28 before rising to $38 then settling back to an exit at $35.   The drop to $28 is the adverse excursion.    The Maximum Adverse Excursion (MAE) is then $2.

For more information see Maximum Adverse Excursion: Analyzing Price Fluctuations for Trading Management by John Sweeney.

(Backtesting Blog is an Amazon Associate.)

Tags: , ,

ATR Trailing Stop Definition

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

The ATR Trailing Stop is one way to limit losses and protect profits. A stop loss order is set a multiple of the Average True Range (ATR) away from the current stock price. As the price moves in the trade’s favor, the stop rachets along with, always calculated from a better closing prices and never from worse closing prices.    This mostly keeps from giving ground once its protected by the stop, except in the case of increasing volatility as measured by the ATR.

Click here for Back Test Performance of Trailing Stops 

Chuck LeBeau popularized the method of trailing a stop loss order a few ATRs below the recent high price for a long trade. This method became known as the Chandelier Stop.    LeBeau’s Book covers other aspects of ATRs.   The best description of the Chandelier exit is in Come Into My Trading Room: A Complete Guide to Trading by Alexander Elder.

The ATR Trailing Stop is also known as a volatility stop.

Extra Insight:

In backtesting, the ATR Trailing Stop reflects each stock’s unique daily price range.  Hence it can fit each stock better than a dollar trailing stop or even a percentage trailing stop.

As with all trailing stops, the ATR trail never exits at the extreme of a movement. Hence it always gives back some of the profits.

The ATR stop amount can be subtracted from either the high, the close, or the low of the day.    Each variation gives slightly different results.    The important concept is to match the stop distance to the stock’s volatility and to move it along with improving prices.

ATR stops are not offered by brokers, to my knowledge.   They are also tedious to calculate by hand.   The only realistic way to use an ATR stop is with software support.   Programmable software packages such as TradeStation can be programmed to display (and backtest!) an ATR stop.   

Click here for BackTesting Reports on Trailing Stops

(Backtesting Blog is an Amazon Associate.)

Last updated 11/11/08.

Tags: , , , , , , , , , , ,

Average True Range Definition

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

The Average True Range (ATR) is a measure of a stock’s volatility.   The idea is to take the day’s range from low to high, including gaps from the previous day and average that range across several days.

The ATR was first described by Welles Wilder in New Concepts in Technical Trading Systems.

Extra Insight:

The ATR can be calculated for any chart time scale, by calculating the true range for each bar and averaging.

Click here for BackTesting Reports on Trailing Stops

(Backtesting Blog is an Amazon Associate.)

Tags: ,

Avg Hold Definition

November 10th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

Avg Hold is also known as the average holding time.  

The holding time is the length of time that the trade is open.   The average is taken across all the trades which resulted from backtesting a particular strategy.

The average holding time is measured on the same scale as the chart time scale.    Since I am backtesting on daily charts, the avg hold is measured in days.

Extra Insight:

When backtesting a strategy, its useful to know the average holding time of all the trades made by that strategy.   This gives an idea of how long the funds are needed - on average — for each trade.   It also gives some insight into the type of trader that might like the strategy.

All else being equal, the trading strategy with the smallest average hold time is best.   Not all things are equal in practice though.   People may seek out longer or shorter hold times based on their temperment, tax situation, global market views, margin, and a host of other factors.   The average hold time gives insight into which strategies will fit these other requirements.  I also use it to classify different strategies and compare those with similar hold times.

Last updated 11/11/08.

Tags: , ,

Backtesting Definition

November 6th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

Backtesting is the process of checking a trading strategy by applying the strategy to historical price data to generate hypothetical trades, then analyzing the results to assess the performance of the trading strategy.

The backtesting engine is the most glorified piece of the operation however it would not be successful without clean data, objective trading strateiges, statiscally sound analysis, and someone to do perform all the tests.

Although most traders concur that backtesting is useful, many traders don’t do it because of the time, expense, and expertise required.    

Backtesting provides a model of trading.   Significant differences with live trading exist such as: commissions, slippage or skid, after hours trading, dirty data, software bugs, human error.  Backtesting results don’t guarantee future performance.    

Backtesting is a screening tool that is really good at eliminating under-performing trading strategies.   If a trading strategy didn’t perform well in the past, it’s unlikely to make money in the future.     

If a set of rules does perform well in backtesting - that’s great but not the end of the game.  Traders ultimately must decide if a given strategy is suitable for their own use.

Last updated 11/11/08.

Tags: , , , ,

Backtesting Engine Definition

November 6th, 2008 by jackieannpatterson | 1 Comment | Filed in Glossary

TradeStation Backtesting Engine Test Channel Trading

TradeStation Backtesting Engine At Work

The Backtesting Engine is the core software doing the backtest. 

It takes as inputs the historical price data and trading strategies.

The backtesting engine applies the trading strategies to the historical price data to get a series of hypothetical trades and records the results.

The outputs of the backtesting engine are typically performance statistics.    I have added instrumentation to gather additional information about each trade for later analysis.

Many backtesting engines are available commerically.    Well-known platforms include TradeStation, Worden Blocks BackScanner, WeathLab, Amibroker.    Many brokers such as TD Ameritrade offer backtesting engines for their customers.

In spite of the wide availability of software, many traders don’t backtest because of the huge amount of work it takes.    Reading a Backtesting Report is much easier.  :-)

Last updated 11/11/08.

Tags: , , , , , , , ,

Baseline Definition

November 6th, 2008 by jackieannpatterson | No Comments | Filed in Glossary

Click here to download the baseline issue of BackTesting Report free without registration.  

The Baseline is the backtesting results from a very simple trading strategy.  We use this as a basis for comparision.   We do this to weed out the trading strategies that look good because they happened by chance to be in sync with the market over the test period.   Instead we want to find the strategies that add value other than just riding the market.

Trading strategies must test out better than the baseline to be considered for live trading.

For example, an entry strategy with a 55% win rate might sound good by itself.   But if the baseline had a 60% win rate over the same stocks and time period, that 55% strategy is actually a loser!

Extra Insight:

We test a simple strategy that enters the market at every opportunity and blindly exits at the end of specified hold periods.   We choose the hold periods to match popular trading styles.  This gives a win rate baseline.   It also shows the market’s directional bias for the test period.  We calculate the expectancy although this is not a real trading strategy.

This sample strategy has some dependence on the start date.    We can measure it to see the impact.   We can also reduce the start date impact by doing a random re-sampling using Monte Carlo simulation to get a more robust baseline.

The difference between “buy and hold” of a benchmark index and the baseline strategy is that the baseline takes into account the transaction costs of commission and slippage.  The baseline also spends a fraction of the time out of the market between trades — overnight in the case of End-of-Day data.

Win rate is my comparision metric for entry strategies.  

Expectancy is my metric for comparison for exit strategies.

Last updated 02/04/09.

Tags: , , , , ,

Benchmark Definition

November 6th, 2008 by jackieannpatterson | 1 Comment | Filed in Glossary

Wilshire 5000 Weekly Chart 4/2004 - 5/2008

Wilshire 5000 Weekly Chart 4/2004 - 5/2008

Most mutual funds quote their performance versus a benchmark — an index which most closely represents the holdings of the fund.

Extra Insight:

Grading a manager solely on performance versus the benchmark is known as relative returns.    This allows managers to quote that they beat the market when the merely lost less than their benchmark index.  

Absolute returns are calculated without reference to the benchmark.   For private individuals and arguably anyone else whose money is on the line, its really absolute returns that matter.

For my backtesting, the Wilshire 5000 is the most relevant index because it represents the widest selection of stocks as does my backtesting data set.   I don’t consider dividends in the backtesting and therefore don’t consider dividends from the index either.

In addition to comparing to holding a market index, its important to compare backtesting results against a very simple baseline strategy to get insight into the basic market behavior of the time period under test.

Last updated 11/11/08.

Tags: , ,