nflverse nflplotR NFL Logo Plots 工具包 User Manual

A set of functions to visualize NFL analysis in ggplot2 plots and gt tables using team logos, wordmarks, and player headshots.


nflverse nflplotR NFL Logo Plots 工具包 User Manual - cover page
Brand
nflverse
Category
Other software
Document type
User Manual
Language
English
Pages
36
File format
PDF
File size
180 KB
Published
29 November, 2026
Updated
29 November, 2026
MD5 checksum
4881EC5C70D22E54A4120EF38640E54C

About this manual

This manual describes the nflplotR package for visualizing NFL data in R. It includes functions to display team logos, wordmarks, and player headshots in ggplot2 and gt tables. The package integrates with ggplot2 and gt for seamless visualization. It also includes utility functions for clearing caches and customizing plot elements.

The package requires R >= 4.1.0 and depends on several R packages including ggplot2, gt, and nflreadr. It provides theme elements like element_nfl_logo() and element_nfl_headshot() to replace text with images in plots. Examples demonstrate how to use these elements in plots and tables.

What's inside

  • .nflplotR_clear_cache
  • element_nfl_logo
  • element_nfl_wordmark
  • element_nfl_headshot
  • geom_from_path
  • gt_nfl_logos
  • gt_nfl_headshots
  • scale_nfl
  • nfl_team_factor
  • nfl_team_tiers

Frequently asked questions

How do I use NFL team logos in a ggplot2 plot?

Use the element_nfl_logo() function in the theme to replace team abbreviations with logos.

How do I use player headshots in a ggplot2 plot?

Use the element_nfl_headshot() function in the theme to replace player GSIS IDs with headshots.

Download PDF (180 KB)