make_lineup: Determine optimal entries against a given opponent lineup

View source: R/make_lineup.R

make_lineupR Documentation

Determine optimal entries against a given opponent lineup

Description

Determine optimal entries against a given opponent lineup

Usage

make_lineup(
  df,
  op_df,
  point_values,
  result_col,
  events = NULL,
  max_entries = NULL,
  max_ind_entries = NULL
)

Arguments

df

a data frame of times for the team to be entered. Must contain column Event with the same event naming convention as op_df, a column with name matching result_col containing times or diving scores, and a column called Name containing athlete names

op_df

a data frame containing the opponent lineup. Must contain column Event with the same event naming convention as df, a column with name matching result_col containing times or diving scores, and a column called Name containing athlete names

point_values

either a recognized string or a list of numeric values containing the points awarded by place. Recognized strings are "hs_four_lane", "hs_six_lane", "ncaa_six_lane"

result_col

the name of a column, present in both df and op_df that contains times and/or diving scores

events

a list of events. If no list is entered then events will be taken from unique(op_df$Event)

max_entries

the number of entries a team is permitted per race. usually half the number of lanes in the competition pool

max_ind_entries

the number of indivdual events a given athlete may enter

Value

a data frame of optimal entries based on df and op_df


gpilgrim2670/SwimmeR documentation built on March 26, 2023, 5:05 p.m.