This function can be used to determine what a lineup would have scored, given projections and actual fantasy points. This makes back-testing different lineup parameters fast and easy.

# S4 method for lineupClass
compare_lineups_with_actuals(object, actuals, show_warnings = TRUE)

Arguments

object

An object of class Lineups

actuals

A data.frame (or data.table, or tibble) containing players and actual fantasy points. See details.

show_warnings

Flag indicating whether warnings should be shown (e.g., "Player X was not found in actuals").

Value

Data.table of lineup comparisons

Details

The actuals data.frame needs to contain a column called actuals that contains actual fantasy points, and at least one of id (player IDs associated with the model run), or fullname. If both identifier columns are present, id will be preferentially used.