theme_tadaark: Official dark tadaa-data ggplot2 theme (for now)

View source: R/theme_tadaark.R

theme_tadaarkR Documentation

Official dark tadaa-data ggplot2 theme (for now)

Description

Because, according to Financial Times Datavizard John Burn-Murdoch, "they look cool".

Usage

theme_tadaark(
  title.size = 16,
  text.size = 14,
  legend.position = "top",
  show.axis = FALSE,
  show.grid = TRUE,
  plot.margin = c(0.8, 0.4, 0.4, 0.8),
  font.base = "Roboto Condensed"
)

Arguments

title.size

title element size in pts.

text.size

text element size in pts.

legend.position

either one of "none", "left", "right", "bottom", "top".

show.axis

boolean or "x", "y"; should axis be drawn? Which?.

show.grid

boolean; should grid lines be drawn?.

plot.margin

margin around entire plot (unit with the sizes of the top, right, bottom, and left margins).

font.base

The base font, defaulting to "Roboto Condensed".

Details

Using this function changes the default color for many geoms via ggplot2::update_geom_defaults, which, unfortunately, is rather complicated to undo. One easy but blunt way is to restart your R session.

Note

Use hrbrthemes::import_roboto_condensed() to install Roboto Condensed.

References

https://twitter.com/jburnmurdoch/status/1231235675229491200

Examples

## Not run: 
library(ggplot2)
p <- ggplot(iris, aes(x = Sepal.Width)) +
  geom_histogram(binwidth = .25) +
  labs(
    title = "Yet another iris plot",
    subtitle = "Using theme_tadaark",
    caption = "Oh hi there, didn't see you walk in"
  )

p + theme_tadaark()

## End(Not run)

tadaadata/tadaathemes documentation built on Feb. 3, 2024, 7:43 a.m.