image thumbnail

Texas Holdem Win Probabilities

version (5.3 KB) by Oliver Rice
Calculates the probability of each player winning a round of Texas Holdem


Updated 07 May 2012

View License

The CardAnalyze function estimates the probability of each player at a table of Texas Holdem winning the round.

Variable inputs are accepted for number of players, player's cards, cards on the table, and number of Monte Carlo iterations to use in estimating probabilities.

The function is able to operate at 3 levels of information

Only one player's cards are known

All players' cards are known

Some of the players' cards are known, some are not.

A 1.7ghz dual core processor is able to calculate 10,000 iterations for 6 players in under 1 second.

Starting a matlab pool will yield a notable speed increase
'matlabpool local'

If speed is still a concern, over half the computational time is spent on the loop call of 'randpermut'. This would be an area to improve.

The original purpose of the function was to develop strategies for identifying player collusion via machine learning.

Cite As

Oliver Rice (2021). Texas Holdem Win Probabilities (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2011b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!