simulate_bets: Simulate Bets

Description Usage Arguments Details Value Examples

Description

Simulate advantage bets

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
simulate_bets(
  probs,
  odds,
  outcomes,
  closing_odds = NA,
  min_advantage = 0.05,
  start_bank = 100,
  stake = 1,
  max_odds = NA,
  bet_placement_matrix = NA,
  season_ids = NA
)

Arguments

probs

Tibble, data.frame or matrix of estimated match probabilities. Columns are outcomes, rows are matches.

odds

Tibble, data.frame or matrix of bookmakers odds. Columns are outcomes, rows are matches.

outcomes

Factor, the levels of which correspond to a column in probs and odds. They must all be ordered in the same way.

closing_odds

Tibble, data.frame or matrix of bookmakers odds. These are the odds at close and not necessarily bet on. These are used to check the closing line value (CLV) of the bets made.

min_advantage

Minimum advantage needed before a bet is placed. Default: 0.1.

start_bank

Starting bankroll units. Default: 100.

stake

Stake to place per bet. Default: 1.

max_odds

Maximum odds which a bet is placed it. You might limit odds to lower variance. Default: 5.

.seed

set a seed, good for testing the sampling in the CLV part or to get reproducible CLV stats

Details

DETAILS

Value

A list of betting statistics.

Examples

1
2
3
4
5
probs <- matrix(runif(9), nrow = 3)
odds <- matrix(runif(9, min = 1, max = 25), nrow = 3)
outcomes <- factor(sample(c("home", "draw", "away"), size = 9, replace = TRUE), levels = c("home", "draw", "away"))

betting_stats <- simulate_bets(probs, odds, outcomes)

neilcuz/panenkar documentation built on June 19, 2021, 7:31 p.m.