Kelly System for position sizing

Jaydee

Established member
Messages
556
Likes
107
Hi all

I have been in a few debates on this forum regarding what % of account equity should be risked - less for a postion trader more for scalping etc. Well, I've been reading a fair bit about gambling maths recently and came across this system for position sizing. Apparently, Warren Buffet uses it a great deal and it does seem to have its charms.

Here's the formula:

F = [W x (P - Q)]/W

Where:
F = Maximum fraction of account equity risked per trade
W = Average payout for a winning trade (measured in odds of W : 1)
P = Probability of winning
Q = Probability of losing (1 - P)

Example, let's say you have done 1000 trades. Going over these you find that 555 are winners and 445 are losers. The 555 winners yielded an average of 2.5:1 over the losing trades. So, plugging this into the formula:

F = [2.5 x (0.555 - 0.445)]/2.5
F = 0.1 = 10%

Obviously, this is the absolute maximum you should bet and because the data you are using is historical and, therefore, unlikely to be perfectly accurate going forward, a trader should discount this figure by a reasonable amount (maybe by 25 - 50%).

I'm trying to modify this so it will work with a situation where you have more losing trades than winning ones but still acheive a positive edge.

Best

JD
 
Last edited:
In my view the Kelly equation only works if you know before each 'bet' the probability of that 'bet' winning (such as card counting in Blackjack with an optimal counting method). In trading or other types of betting (on sports etc.) I don't think it will work because with those 555 out of a 1000 winners in your example it's not right to believe the probability of a win on each was exactly 0.555
 
The application of Kelly (or half-Kelly) to trading is that you keep running statistics of your trades - with #wins:#losers, $win:$lose, and so on.

Then take a sample of say the last 30 trades, do the sums, plug these sums into Kelly, and hey presto. Rinse and repeat.

Added bonus is that if you are performing badly, it will be reflected in the last 30 trades (if you have done 5,000 of them, a string of bad ones isn't going to impact your stats) - and so Kelly will tell you to place smaller trades, exactly what you want if things are going tits up - and vice versa.
 
In my view the Kelly equation only works if you know before each 'bet' the probability of that 'bet' winning (such as card counting in Blackjack with an optimal counting method). In trading or other types of betting (on sports etc.) I don't think it will work because with those 555 out of a 1000 winners in your example it's not right to believe the probability of a win on each was exactly 0.555

That's a fair comment. However, the higher the sample size of trades you have, you are likely to get a reasonably accurate result. As it isn't possible to know what chance a trade has of winning, the best the trader can do is work with averages over a large sample size.

The application of Kelly (or half-Kelly) to trading is that you keep running statistics of your trades - with #wins:#losers, $win:$lose, and so on.

Then take a sample of say the last 30 trades, do the sums, plug these sums into Kelly, and hey presto. Rinse and repeat.

Added bonus is that if you are performing badly, it will be reflected in the last 30 trades (if you have done 5,000 of them, a string of bad ones isn't going to impact your stats) - and so Kelly will tell you to place smaller trades, exactly what you want if things are going tits up - and vice versa.

Just so I understand, Mr Gecko, you are saying that it is better to base it on a smaller number of recent trades as more recent data is more relevant to the future?
 
I have been in a few debates on this forum regarding what % of account equity should be risked - less for a position trader more for scalping etc.

That is not how I and many others do it. The percentage of account to be risked remains constant and it is the size of the trade that is adjusted for volatility of the time frame being traded. So let's say that I use a $50,000 account and I am happy to risk 1% on any trade. I have measured the volatility of an instrument to be 10 pips and I am intra-day trading. Then the size I will use is (50000 x 0.01)/10 = $50 per pip. Now if I am swing trading and measure volatility to be 50 pips then the size I will put on is (50000 x 0.01)/50 = $10 per pip

My overall risk is the same for each trade, ie $500 and it is the time frame of the trades that is the determining factor in deciding how much size to use.


Paul
 
There is a lot of misinformation regarding this Kelly System - I think it's because it originally started out as something to help with AT&T's telephone signals before it was used by gamblers and then investors. Therefore, there have been a few modifications with the basic formula.

Right, this formula solves the issue of having more losers than winners but still having a positive expectation:

F = P - [(1-P)/W]

Where the letters mean the same as the equation above.

E.G. 1:

1000 trades - 555 winners, average winner is 2.5:1 over average loser

F = 0.555 - [(1 - 0.555)/2.5]
F = 37.7%


E.g. 2:

1000 trades, 400 winners, average winner 3:1 over the average loser

F = 0.4 - [(1 - 0.4)/3]
F = 0.2 = 20%


These percentages seem a little high.
 
Last edited:
That is not how I and many others do it. The percentage of account to be risked remains constant and it is the size of the trade that is adjusted for volatility of the time frame being traded. So let's say that I use a $50,000 account and I am happy to risk 1% on any trade. I have measured the volatility of an instrument to be 10 pips and I am intra-day trading. Then the size I will use is (50000 x 0.01)/10 = $50 per pip. Now if I am swing trading and measure volatility to be 50 pips then the size I will put on is (50000 x 0.01)/50 = $10 per pip

My overall risk is the same for each trade, ie $500 and it is the time frame of the trades that is determining factor in deciding how much size to use.


Paul

Hi Paul

I understand that but it's possible that if you have a high enough win rate, 1% of account equity isn't enough. Maybe 2 or 3% is actually what a trader should be using to maximise their returns.

I also risk 1% per trade, but I'm in the position now where I am looking to risk more and use some maths to find the optimal risk percentage based on my trading records. The 1% is just a rule of thumb that a number of us use on here, but the optimal amount to risk may be a good deal more (or less if the win % is low enough).

JD
 
Here is an article that clarifies what the Kelly formula means and its use:

http://www.tradingpatterns.com/Kelly.pdf

Another one on percentage position sizing:

http://www.tradingpatterns.com/PositionSizing.pdf

Interesting stuff.


Yes, I've just been reading at Kelly.pdf. I also realise I made a mistake with the original formula in my first post which is why the two formulae gave differing results with the same stats. I have now put this right:

F = (WP - Q)/W
 
The percentages only seem high because people have been brainwashed into this two percent thing!
 
The percentages only seem high because people have been brainwashed into this two percent thing!

QFT

If your figures are right (and if you're running different systems obviously you have to distinguish between different types), the kelly criterion is what you should bet for maximum returns.Have looked into this from my thread from first principles but nobody seemed much interested.


Personally I'm for kelly over 2% if you have a decent set of past data, mainly because it has a proof as opposed to just being popular (soon at 95% lose money, doing the done thing probably isn't the best idea...whether people do what they preach is a different matter). If you're worried about risking large sums of your account then you're probably giving into fear and probably shouldn't be trading with that money.
 
The percentages only seem high because people have been brainwashed into this two percent thing!

That's very likely, but there is a problem with this Kelly idea is that it doesn't account for a series of bad trades (call it a six sigma situation if you like).

For example, say you got 500 winning trades at 2.5:1 return and 500 losers - 50:50. Statistically you will experience a run of 10 losing trades every 1024 trades you do. The Kelly system says to trade 30% for each trade and, therefore, losing ten trades in a row will cause a trader to experience a draw down of over 97% sticking to the Kelly Criterion.

Therefore, in the formula:

F = (WP - Q)/W

the W divisor doesn't account for a run of such bad luck. I think the divisor (W) should be multiplied by a constant figured out from some normal distribution stats modelling of a traders past trades.

What do you think?

QFT
If your figures are right (and if you're running different systems obviously you have to distinguish between different types), the kelly criterion is what you should bet for maximum returns.Have looked into this from my thread from first principles but nobody seemed much interested.

Hi Hotch, I will take a look at your original post on this.
 
The corraly of course is ten winners and you will have multiplied your stake almost 270 times.

The problems are with human psyche, market liquidity (very important in fact - you can't trade half a lot and you can't trade a million lots without moving the market) and most importantly by far uncertainty about what your real risk reward is. However it is a good illustration of why it pays to be aggressive.
 
The problems are with human psyche, market liquidity (very important in fact - you can't trade half a lot and you can't trade a million lots without moving the market) and most importantly by far uncertainty about what your real risk reward is.

Yes, I totally agree. These are all things to take into consideration and, above all, the Kelly System works on the basis that it is a maximum risk percentage and nothing more. Still seems a bit high, regardless.

In light of this, I'm going to try and develop a Perfect World mathematical solution (one that makes basic assumptions and ignores Arabianights' perfectly valid points for the sake of simplicity) which should fix Kelly's over risk issue - I hope it will provide a better approximate risk figure.

The formula will be similar to Kelly:

F = (WP - Q)/WK

Where K is the mystery constant I'm working on based on a trader's likelihood of experiencing a run of losing trades. I'm working this out using an exponential chart with a negative gradient - this curve has an optimum point where by decreasing the risk further gives no extra benefit. It is this point that the gradient can be used to solve K. However, I can't figure out what the bleeding gradient is (my maths isn't as strong as it used to be, I'ved forgotten a lot of the calculus based stuff) - bear with me.
 
Can I suggest the Poisson distribution as somewhere to look for your factor K...
 
Or maybe a monte carlo... If you're heading down the road I think you are there won't be an analytical solution.

Anyone here familiar with a fractal model of asset prices?
 
The problems are with human psyche, market liquidity (very important in fact - you can't trade half a lot and you can't trade a million lots without moving the market) and most importantly by far uncertainty about what your real risk reward is.
Very astute observations. I don't know if they were intended to describe difficulties associated with variable sizing; nonetheless, I believe they nicely do so.
 
Or maybe a monte carlo... If you're heading down the road I think you are there won't be an analytical solution.

Anyone here familiar with a fractal model of asset prices?

Can I suggest the Poisson distribution as somewhere to look for your factor K...

Will take on both of these ideas. My original method was flawed so thanks for the inspiration.
 
Have to say I agree with Arabian - you aren't going to find an a priori result for this.
 
Have to say I agree with Arabian - you aren't going to find an a priori result for this.

Yes, I think you're both right. I'm going to enlist the help on on of my Uni friends - he's a Maths Phd on symmetry and group theory but he's also very much into maths theories on gambling. I have a feeling he'd be interested in this subject and, therefore, think he's my best bet to try and push forward on this. We'll see...
 
Top