ffs_optimise_lineups | R Documentation |
Calculates optimal lineups for all franchises in the dataframe based on a table of lineup constraints.
ffs_optimise_lineups( roster_scores, lineup_constraints, lineup_efficiency_mean = 0.775, lineup_efficiency_sd = 0.05, best_ball = FALSE, pos_filter = c("QB", "RB", "WR", "TE") ) ffs_optimize_lineups( roster_scores, lineup_constraints, lineup_efficiency_mean = 0.775, lineup_efficiency_sd = 0.05, best_ball = FALSE, pos_filter = c("QB", "RB", "WR", "TE") )
roster_scores |
a dataframe as generated by |
lineup_constraints |
a dataframe as generated by |
lineup_efficiency_mean |
the average lineup efficiency to use, defaults to 0.775 |
lineup_efficiency_sd |
the standard deviation of lineup efficiency, defaults to 0.05 |
best_ball |
a logical: FALSE will apply a lineup efficiency factor and TRUE uses optimal scores as actual scores, default = FALSE |
pos_filter |
a character vector specifying which positions are eligible - defaults to |
Lineup efficiency is the percentage of optimal/best-ball score that is used as the actual score - by default, the lineup efficiency for a team in non-best-ball settings is normally distributed around a mean of 77.5% and a standard deviation of 5%.
a dataframe of what each team scored for each week
vignette("custom")
for example usage
# cached examples roster_scores <- .ffs_cache("roster_scores.rds") lineup_constraints <- .ffs_cache("mfl_lineup_constraints.rds") ffs_optimise_lineups(roster_scores, lineup_constraints)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.