Page 1 of 1

Optimisation of trading strategies

Posted: Fri Mar 14, 2008 3:07 pm
by alichambers
Hello,

Does anyone use other Optimisation statistics to rank optimisations by?

For example, instead of using raw profit gained, does anyone use Win:Loss Ratio or Risk:Reward ratio - and what are your opinions.

Thanks,
Alex

Posted: Fri Mar 14, 2008 6:11 pm
by eudamonia
Alex,

Depends on the strategy. Is it a high win ratio with a even risk to reward or are you pursuing large R trades with a lower win ratio?

For scalping 1 to 1 R I find that fitness functions such as Michal's equity deviation (essentially it optimizes for as straight an equity curve as possible) works very well.

For large R seeking systems with lower hit rates I find raw profit/max drawdown to be a good fitness function.

Edward

Posted: Sat Mar 15, 2008 12:06 pm
by alichambers
Hi Ed,

Thanks. I'm finding that by optimising for highest account value, I go through long periods of drawdown, then a small % of trades make a killing (eg: 46% wins, 2:1 Win to Loss ratio overall). This is not what I'm looking for.

I'd like to try and smooth out the equity curve to give more of a balance between making a large capital gain and also regular cashflow. I have written my own backtester (from another thread), so am wondering how to sort my results to give this balance - I have the following stats:

- % Wins
- Win:Loss Ratio (All profits/All losses)
- Risk:Reward

I have found that by sorting results by Risk:Reward does not give good overall account balances.

You mention Michal's equity deviation - would this give the balance between large account value but also regular cashflow?

Cheers,
Alex

Posted: Tue Mar 25, 2008 10:12 pm
by michal.kreslik
Just briefly:
  • the more leverage you expect to apply to your trading system, the more linear the equity curve should be
  • if you're already trading at the liquidity limit of the market, then you're no longer interested in the linearity of the equity curve, but instead in the highest equity peak that occured during your testing (so not in the state of your equity on the last bar/tick in your data)

Michal

Posted: Wed Mar 26, 2008 5:19 pm
by eudamonia
Those are some great tips Michal.

ali and others,

If you are trading for you own account you may want to optimize in a fashion that gives you results that you can live with.

Some of the best systems go through prolonged flat periods and/or drawdowns.

Determining what your objectives/tolerances are while trading will go a long way towards helping you operate your system more effectively. It isn't enough to just say you want to make money.

For example a system that has a winning percentage of 50% has an approximately 1/10000 chance of having 19 losers in a row. If you are trading that methodology at the "standard" 2% risk (or even higher at 3%) then you will be in a 38% drawdown (or 57% respectively). Most traders would puke their positions at that point and potentially throw in the towel. If you were trading at a 1% risk (or less as most professional money managers do) then you would see a more reasonable 19% drawdown (still high but not devastating).

Remember also that the statistics above are based on a "normal" distribution of trades. However, the market is non "normal" in its returns/losses and so the probability of having 19 losers in a row in our above example is not so far fetched (particularly if you are trading thousands of trades per year as many traders are).

My point in talking about risk and position sizing here does indeed have a point regarding optimization. That is - we cannot control anything in the markets except risk. As Michal pointed out the more leverage you expect to apply to your trading system, the more linear your equity curve should be (thus if that linearity becomes broken in future trading you will know immediately if something is wrong). The other approach if your system is not optimized for linearity is to utilize minimal leverage so that you do not "break" your system when that 1/10000 probability losing streak occurs.

Edward

Little error on prob calc

Posted: Sat Apr 12, 2008 4:40 am
by pitboss
Opps, Eudamonia little error in ur probability calculation (someone is always being picky, lol).

With a 50% win factor, it is closer to 13 consecutive losers to realize 1/10000 (.00012 - 8,191 to 1) having a draw down of 27% using a 2% risk. A $10,000 bankroll would have been reduced to $7,690.

To have 19 consecutive losers is .0000019 which is 524,287 to 1 has a draw down of 32% using a 2% risk. A $10,000 bankroll would have been reduced to $6,812.

However the basis of your argument is correct. It would be important to add this tid-bit: The greater the number of "decisions" made during a period, the less advantage needed to get to a specific number with the inverse being also true - the fewer the number of "decisions made during a period, the greater advanted needed to get to a specific number.

As an illustration: A craps table with a bettor taking the best possible bet is approx a 1.4% advantage for the house with around 160 decisions per hour. This translates into $1*.014*160=$2.24 per hour. Whereas a person playing keno with the best odds against them is 25% but the house only gets about 9 decisions per hour which translates into $1*.25*9=$2.25 hourly. The more decisions per hour needs less "advantage" than the fewer decisions per hour to equal the same resulting number.

Posted: Sat Apr 12, 2008 9:50 pm
by eudamonia
Pitboss,

Thanks for the correction.

Edward