Applies an ESPN-inspired theme to a GT
object.
This function styles a GT
object with a look inspired by ESPN’s data tables.
Parameters
gt : GT
-
An existing GT
object.
Returns
: GT
-
The themed GT
object, allowing for method chaining.
Examples
from great_tables import GT, md
from great_tables.data import gtcars
import gt_extras as gte
gtcars_mini = gtcars[["model", "year", "hp", "trq"]].head(5)
gt = (
GT(gtcars_mini, rowname_col="model")
.tab_stubhead(label=md("*Car*"))
.tab_header(title="Car Collection")
)
gt.pipe(gte.gt_theme_espn)
Car Collection |
Car |
year |
hp |
trq |
GT |
2017 |
647.0 |
550.0 |
458 Speciale |
2015 |
597.0 |
398.0 |
458 Spider |
2015 |
562.0 |
398.0 |
458 Italia |
2014 |
562.0 |
398.0 |
488 GTB |
2016 |
661.0 |
561.0 |