Welcome to Tennis Probability’s documentation!

This package recursively calculates the probability of winning a tennis match, game, or set.

Functions

find_p(probability, accuracy_threshold)

This functions finds the p value from the probability of winning a game.

game(score_a, score_b, p)

Recursively calculates the probability of player A winning at any state in a game.

match(sets_won_a, sets_won_b, p[, ...])

Recursively calculates the probability of player A winning at any state in a match.

set(games_won_a, games_won_b, p)

Recursively calculates the probability of player A winning at any state in a set.

Classes

InvalidInput

InvalidProbability

NegativeNumber