Translate team abbreviations into logos and render these images in column labels of 'gt' tables.
Usage
gt_sdv_cols_label(
gt_object,
columns = gt::everything(),
league,
height = 30,
mark_type = c("logo", "wordmark", "headshot"),
id_system = "auto",
season = NULL,
strict = FALSE
)Arguments
- gt_object
A table object created using
gt::gt().- columns
The columns whose labels should be replaced with logos.
- league
A league key from
sdv_leagues().- height
The absolute height (px) of the image.
- mark_type
One of
"logo","wordmark"or"headshot": whether the column names are teams (logo / wordmark) or player IDs (headshot).- id_system
How the column names are read.
"auto"(the default) issdv_logo_url()'s automatic reading for logo and wordmark labels, and means"espn"whenmark_type = "headshot"; otherwise as insdv_headshot_url().- season, strict
For logo and wordmark labels only (headshots take neither): the season whose mark to show, and whether an unresolved label is an error. With
strict = TRUEevery label that is not a team errors, including the non-team columns the defaultcolumns = gt::everything()takes.



