get_players_from_data_frame: Get Players from data.frame

View source: R/get-players-from-df.R

get_players_from_data_frameR Documentation

Get Players from data.frame

Description

Get Players from data.frame

Usage

get_players_from_data_frame(df)

Arguments

df

A data.frame with columns for player related information. This can contain any/all of the player related info. If a column coincides with a slot in objects of class player_object, it will be included when the data.frame is converted into unique player objects. The one exception is slot game_info, which is ignored in the conversion.

Details

The following columns are required, in order to avoid issues with the optimizer model:

  • first_name

  • last_name

  • team

  • position

  • salary

  • fpts

You'll get an error if these aren't included. If you want to know what else you can include, run list_player_attributes()

Value

A list containing values of class player_objects, one per player (i.e., row) in the data set.


anthonyshook/dfsOptimizer documentation built on Jan. 4, 2023, 11:36 a.m.