rankPlayedInference

Barry Zeeberg [aut, cre]

2026-05-05

 

 

rankPlayedInference

Barry Zeeberg



Motivation

This package is primarily intended to provide some inferences that might be useful in my upcoming R package playWholeHandDriverPassParams1.

When playing the hearts card game, if you are void in the suit that was led 2, you have a free choice of suit and rank of discard. There may be exceptions based on tactical considerations, but generally you will pick the highest (or co-highest of adjacent ranks) card of the discard suit, in order to minimize the chance of later taking in a trick that contains points.

The more cards of the suit a player holds, the less restrictive and the more choices for the rank of the discard. With a lot of cards in the suit, the player can pick a high card to discard. With only one card in the suit, there is no option, and the discard might be a two or three. In a probabilistic sense, the rank of the discard can be used as a proxy for the length of the suit. If your opponent discards a low card, then an experienced player will note the opponent had only that one card of the discard suit. On the other hand, your opponent discarding a king will suggest there were several cards to choose from in the discard suit. These are sound inferences, and the goal in this study is to provide this inference with a more quantitative interpretation.

For a given suit, if you add up the number of cards that you hold, plus the number that has been played so far, you can easily determine the number that remains in the combined hands of your three opponents. You can also determine the (“special”) card of highest rank of the remaining cards for that suit. At some point, you notice that a certain opponent discards that special card. What can you infer about his holding in that suit?

A series of simulation studies are reported here that allows a quantitative inference based on the conditional probability, given that the opponent has the special card. The same procedure is also used for the conditional probability, given that the opponent does not have the special card.


Methods

The underlying randomization for the simulation is based on the “sample()” function

bin_assignments <- sample(1:3, length(ranks), replace=TRUE)

where the three “players” (1:3) are randomly sampled and assigned to each of the n = length(ranks), which are represented as 1:n, where n is the number of cards that remain in the combined hands of your three opponents.


Results

The results for simulations with 100,000 iterations are shown in Figures 1-12.

Figure 1. Conditional Probability Distributions for 2 Cards in Three Opponents Players Hands
Figure 1. Conditional Probability Distributions for 2 Cards in Three Opponents Players Hands


Figure 2. Conditional Probability Distributions for 3 Cards in Three Opponents Players Hands
Figure 2. Conditional Probability Distributions for 3 Cards in Three Opponents Players Hands


Figure 3. Conditional Probability Distributions for 4 Cards in Three Opponents Players Hands
Figure 3. Conditional Probability Distributions for 4 Cards in Three Opponents Players Hands


Figure 4. Conditional Probability Distributions for 5 Cards in Three Opponents Players Hands
Figure 4. Conditional Probability Distributions for 5 Cards in Three Opponents Players Hands


Figure 5. Conditional Probability Distributions for 6 Cards in Three Opponents Players Hands
Figure 5. Conditional Probability Distributions for 6 Cards in Three Opponents Players Hands


Figure 6. Conditional Probability Distributions for 7 Cards in Three Opponents Players Hands
Figure 6. Conditional Probability Distributions for 7 Cards in Three Opponents Players Hands


Figure 7. Conditional Probability Distributions for 8 Cards in Three Opponents Players Hands
Figure 7. Conditional Probability Distributions for 8 Cards in Three Opponents Players Hands


Figure 8. Conditional Probability Distributions for 9 Cards in Three Opponents Players Hands
Figure 8. Conditional Probability Distributions for 9 Cards in Three Opponents Players Hands


Figure 9. Conditional Probability Distributions for 10 Cards in Three Opponents Players Hands
Figure 9. Conditional Probability Distributions for 10 Cards in Three Opponents Players Hands


Figure 10. Conditional Probability Distributions for 11 Cards in Three Opponents Players Hands
Figure 10. Conditional Probability Distributions for 11 Cards in Three Opponents Players Hands


Figure 11. Conditional Probability Distributions for 12 Cards in Three Opponents Players Hands
Figure 11. Conditional Probability Distributions for 12 Cards in Three Opponents Players Hands


Figure 12. Conditional Probability Distributions for 13 Cards in Three Opponents Players Hands
Figure 12. Conditional Probability Distributions for 13 Cards in Three Opponents Players Hands


In all figures, it is apparent that the conditional probability distribution is shifted to the right relative to the other probability distributions. The degree of shifting depends on the number of cards that are jointly held by the three opponents. For example, in the cases shown in Figures 1 and 2, the shift is barely noticeable.

In contrast, Figure 7 shows the conditional probability distributions for a total of 8 cards (in a given suit) remaining in the three opponents hands. When a player discards the special card, the probability distribution has a maximum around 3 or 4 cards in that player’s hand. On the other hand, when a player discards a low card, the probability distribution has a maximum at 2 cards in that player’s hand. These inferences have significant consequences for reconstructing the three unseen hands, and also for a possible immediate decision of whether or not it is safe to lead that suit on the next trick.

A further level of inference is possible if the winner of this trick (Player A) leads the discard suit on the next trick. For instance, if a player (Player B) had discarded a low card, there is an inference that Player B might now be void. If Player A leads a middle or high rank card of that suit, then it is likely that Player A holds the QS, else he might be concerned lest he take the QS on the next trick. So the perfect reasoner might draw 2 inferences: Player B has a short or void suit, and Player A holds the QS.

As mentioned above, this package is primarily intended to provide some inferences that might be useful in my upcoming R package playWholeHandDriverPassParams. In that package, we are interested in estimating how an inference drawn during the play of the hand might affect the numerical probabilities of particular cards being in particular opponents hands.


Variations on a Theme

Near the end of a hand, when there are just a few cards remaining for each player, you might find yourself on lead with two cards in a certain suit, one high and one low. Say that there are three cards of that suit still out, known to be divided among two opponents. In practice, the three cards are usually divided so that player A has two cards, and player B has 1 card. In order to effect an exit from your hand, you need to make an educated guess as to whether to lead your high or low card.

Player B has no choice of which card to play. If you play your low card, then it is likely that player B will be forced to win that trick, and then has no more cards in that suit to lead and throw you back in. On the other hand, if you lead your high card, Player A will exercise his option to discard his high card under yours, and you might be stuck in your hand, unable to throw player A back in on your next lead.


Additional Opportunities for Card Reading

Some players will discard the ranks of a suit randomly. This has the advantage of making it harder for the opponents to read his hand. However, this carries the risk of possibly holding on to a high card that might take in points later in the hand.

In contrast, many players will discard the ranks of a suit sequentially from top down, in order to get rid of the dangerous high cards as early as possible. This has the disadvantage of making it easier for the opponents to read his hand. But that is true only if the opponents pay attention to the discards.

The moral of this story is that you should develop the knack of picking up on these kinds of hints.


Do Ideas from Partnership Signalling in Bridge have Correlates in Hearts?

Unlike the basic version of Hearts 3, Bridge is a partnership game. When one side is defending a contract, they use many types of signals to communicate with one another. One common type of signal is to play a high card to indicate a strength or a preference. Of course, the opponents are free to view and interpret the signals, as well as the intended partner.

Is it possible that in Hearts, the ranks of cards played can be interpreted as perhaps (intended or unintended) signals?

We already saw above that the discard of a low card in a suit can indicate that opponent is now void in that suit, and might therefore dump the QS on the next lead of that suit. In contrast, the play of a high card can indicate that opponent holds several cards in that suit, since he had the luxury of choosing the best rank to discard. If there is a prior reason to believe that opponent also holds the QS, it might be safe to play another round or two of that suit without fear of taking the QS.

This interpretation of discards is very similar to the partnership communication in Bridge. The bottom line is that playing a low card might discourage a lead in that suit, and playing a high card might encourage a lead in that suit.


Psychological Warfare

An advanced aspect of Hearts (as well as Bridge) is the art of “Deceptive Play.” An advanced player might purposely use “psychological warfare” (misleading rank discards) to deceive the opponents. Of course, this is a waste of time if you are playing against beginners or careless players. And of course world class expert players might see through a naive attempt to deceive; the tactic might need to be part of sequence of carefully crafted deceptions that work together to paint a compellingly consistent false picture.

Two specific instances come to mind that where deceptive play might be of benefit:


Epilogue4

There are tons of books published on Bridge, and these books cover all levels from introductory to the most advanced. In stark contrast, there are very few books on Hearts, maybe just one or two, mostly oriented towards beginners. But many of the strategies and tactics in Bridge translate directly into Hearts, so you should read Bridge books if you want to improve in Hearts.

Books on Hearts and Bridge
Books on Hearts and Bridge

  1. I have written three additional documents related to the general topics of card reading and drawing inferences. The most comprehensive is Drawing_Inferences.pdf, which will be included in the upcoming package playWholeHandDriverPassParams. The other two are vignettes and .pdf’s included in my published packages evenBreak and conditionalProbNspades.↩︎

  2. To keep the discussion clearer, I referred to cases of discards when void in the suit led. But the entire discussion also applies when the leader plays a high card, and the other players are following suit with ranks that are below the leader’s card. If a player follows with a very low card, then there is a danger that player might now be void and poised to dump the QS on the next lead of that suit. So the leader may very well decide to shift suits on the next lead, rather than take the chance of playing off another high card in the original suit.↩︎

  3. Not exactly true. Temporary partnerships in basic Hearts can form and dissolve and re-form as the game progresses. If one player has a much lower score than the others three players, those three players form an alliance against the leader.↩︎

  4. Like “The Fugitive” television show, I am taking the liberty of being so audacious as to add an epilogue. “Tightrope” also had what amounted to an epilogue, but did not it call it that explicitly.↩︎