test.bracket | R Documentation |
Test a bracket
test.bracket(
bracket.empty,
bracket.picks,
prob.matrix = NULL,
prob.source = c("pop", "kenpom", "538"),
pool.source = c("pop", "kenpom", "538"),
league = c("men", "women"),
year = current.year,
pool.bias = NULL,
pool.size = 30,
num.sims = 1000,
bonus.round = c(1, 2, 4, 8, 16, 32),
bonus.seed = rep(0, 16),
bonus.combine = c("add", "multiply"),
print.progress = TRUE,
shiny.progress = NULL
)
bracket.empty |
a length-64 character vector giving the field of 64 teams in the tournament, in order of initial overall seeding |
bracket.picks |
an length-63 character vector encoding your picks (this is the bracket to be evaluated) |
prob.matrix |
a matrix of probabilities, with rows and columns corresponding to teams, matching the output of bradley.terry(). This probabilities are used to simulate outcomes on which to evaluate bracket.picks. If NULL, prob.source is used. |
prob.source |
source from which to use round probabilities to simulate outcomes — "pop": ESPN's population of picks (default), "kenpom": Ken Pomeroy's predictions (kenpom.com), or "538": predictions form fivethirtyeight.com. Ignored if prob.matrix is specified. |
pool.source |
source from which to use round probabilities to simulate entries of opponents in pool. Same options as prob.source. |
league |
which league: "men" (default) or "women", for pool.source. |
year |
year of tournament, used for prob.source. Ignored if prob.matrix is specified. |
pool.bias |
character vector of names of teams to whom home-team bias is to be applied (must match name column of pred.pop.[league].[year]). Ignored unless pool.source is "pop" (see ?add.home.bias for details). |
pool.size |
number of brackets in your pool (excluding yours), matters only if criterion == "win" (default is 30) |
num.sims |
number of simulations over which to evaluate the candidate brackets (default is 1000) |
bonus.round |
a length-6 vector giving the number of points awarded in your pool's scoring rules for correct picks in each round (default is 2^round) |
bonus.seed |
a length-16 vector giving the bonus awarded for correctly picking winner based on winner's seed (default is zero) |
bonus.combine |
how to combine the round bonus with the seed bonus to get the number of points awarded for each correct pick: "add" (default) or multiply |
print.progress |
should progress be printed to console? |
shiny.progress |
a shiny::Progress object used only for the Shiny app |
sspowers
prob.matrix = bradley.terry(games = games.men.2018)
my.bracket = find.bracket(bracket.empty = bracket.men.2018,
prob.matrix = prob.matrix, pool.source = "pop", league = "men",
year = 2018)
result = test.bracket(bracket.empty = bracket.men.2018,
bracket.picks = my.bracket, prob.matrix = prob.matrix,
pool.source = "pop", league = "men", year = 2018)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.