Your advice: what's a reasonable way to test RANDOM EXITS?

Discussions about the testing and simulation of mechanical trading systems using historical data and other methods. Trading Blox Customers should post Trading Blox specific questions in the Customer Support forum.
Post Reply
Roundtable Knight
Roundtable Knight
Posts: 2987
Joined: Fri Jun 11, 2004 2:50 pm

Your advice: what's a reasonable way to test RANDOM EXITS?

Post by sluggo » Thu Mar 22, 2007 1:59 pm

We've seen the Tharp-Basso system that makes trade entries at random, then uses a trailing stop to exit (link). But what about the reverse: a system that makes trade exits at random, but lets us use our favorite type of entry. To my knowledge, nobody has ever discussed such a thing.

It got me wondering: What is the most reasonable way to "test random exits"? What plan of testing is the fairest? On my own I came up with a few ideas, but would love to hear YOUR ideas for how to "test random exits".

I thought of these:
  1. Wait for your entry signal to make a trade entry. Then go ahead and enter the market according to that entry signal. Remain in the trade for "D" days after entry, then exit at the market price at the end of the D'th day. "D" is a number chosen at random, uniformly distributed between D=1 days and D=100 days (or whichever boundaries you like).
  2. Same as #1 except the random numbers D follow a probability distribution of trade holding times that resembles a real-world trading system's holding time distribution. For example, Figure 1 below is taken from straight from the Blox backtest of a futures trading system; it is column U of "Trade Log.csv".
  3. You restrict yourself to entry signals taken from pure-reversal systems that are always in the market, either long or short but never out. The random number generator is used to generate random DATES (rather than random trade holding-times). For each exit date, you look back and see what was the most recent entry signal. Then your "trade" consists of that most recent entry signal, plus the randomly chosen exit date.
I am not so fond of #3 because it seems too restrictive to forbid any kind of entry signals. After all we are trying to answer the question, "How profitable is a system that uses a good entry but exits at random?" and it seems unwise to forbid any kinds of good entries.

Would love to hear your thoughts.

Figure 1. Holding times
histog.png (9.29 KiB) Viewed 11175 times

Jens Albrecht
Senior Member
Senior Member