set_flex_positions-optimizer-method.Rd
Method for setting FLEX/UTIL positions. Can be used to limit FLEX/UTIL to a user-specified set of possible positions (see examples).
# S4 method for optimizer
set_flex_positions(object, positions)
An optimizer object
Value to set the roster size (subject to validity checks).
Updated Optimizer object
if (FALSE) {
opt <- create_optimizer(site = 'DRAFTKINGs', sport = 'HOCKEY')
opt <- add_players_from_csv(object = opt, filepath = '/Path/to/file.csv')
# Default FLEX is c('C','W','D') -- here we'll remove D
opt <- set_flex_positions(object = opt, positions = c('C','W'))
}