get_player_vect_own: Get Contest Ownership for multiple players in the same lineup

View source: R/Analysis External functions.R

get_player_vect_ownR Documentation

Get Contest Ownership for multiple players in the same lineup

Description

Returns ownership

Usage

get_player_vect_own(lu_dat, lineup_players, set_type = "intersection")

Arguments

lu_dat

Takes lineup data, long and tidy, or summarized and tidy.

lineup_players

vector of player names as they appear in DKSalary file

set_type

Which type of subset the function will return. 'intersection' is default and will return lineups that contain all the players in the linuep_players vector. Alternatively, 'union' will return lineups which contain at least 1 of the players in the lineup_players vector.

Value

a subset of lu_data containing players in the lineup_players vector.

Examples



 ## return lineups which contain both Dak Prescott and Amari Cooper
 get_player_vect_own(lu_dat, c('Dak Prescott', 'Amari Cooper'), set_type = 'intersection') 




Dmunslow/tidyDK documentation built on Nov. 8, 2022, 8:53 a.m.