Description Usage Arguments Value Examples
Compute and update ELO scores for a single time slice. Within the time slice all matches are assumed to be happening in parallel.
1 2 3 4 5 6 7 8 9 10 | pm_eloRunTimeSlice(
eloDB,
matchDB,
simDF,
simulateResults = FALSE,
tennisElo = TRUE,
Cfactor = 250,
Coffset = 5,
Cshape = 0.4
)
|
eloDB |
a dictionary of player ELO scores |
matchDB |
a dictionary of matches a player has played |
simDF |
a dataframe of matches to process. Requires at least 'player_name', 'opponent_name' and 'actualResult' columns |
simulateResults |
Whether to overwrite actualResult with simulated outcomes |
a list with three items: the updated eloDB, the updated matchDB and the input simDF updated with ELO columns. New columns are prefixed with 'elo_'
1 2 3 4 5 6 | tmpres = pm_eloPrepDatabase(unseenDataPlayers=c('bob','charlie','david'))
eloDB = tmpres$eloDB
matchDB = tmpres$matchDB
mysim = tibble::tribble(~player_name,~opponent_name,~match_date,~actualResult,
'bob','charlie',as.Date('2007-01-01'),1)
tmpres = pm_eloRunTimeSlice(eloDB,matchDB,mysim)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.