A modern ggplot theme

theme_vmodern(
  base_family = "",
  size_preset = NULL,
  bg_color = "grey98",
  strip_bg_color = "#2c3e50",
  grid_color = "grey90",
  axis_line_width = 1,
  show_ticks = TRUE,
  x_text_angle = FALSE,
  axis_title_size = 10,
  axis_text_size = 7,
  legend_title_size = 10,
  legend_text_size = 8,
  strip_text_size = 9,
  title_size = 12,
  ...
)

Arguments

base_family

Base font family.

size_preset

One of "small", "medium", "large", "xlarge", or "some number of x'slarge" indicating the default sizes for plot text and titles. If NULL, defaults to values specified explicitly by axis_title_size, axis_text_size, legend_title_size, legend_text_size, strip_text_size, title_size.

bg_color

Color for plot background.

strip_bg_color

Color for strip background (for ggplot2::facet_grid() and ggplot2::facet_wrap()).

grid_color

Color of panel grid major axes or NULL if want no major grid lines.

axis_line_width

Width of x and y axes lines.

show_ticks

Logical; whether or not to show axes tick marks.

x_text_angle

Logical; whether or not to angle x text at 45 degrees.

axis_title_size

Font size of axis title. Ignored if size_theme not NULL.

axis_text_size

Font size of axis text. Ignored if size_theme not NULL.

legend_title_size

Font size of legend title. Ignored if size_theme not NULL.

legend_text_size

Font size of legend text/key. Ignored if size_theme not NULL.

strip_text_size

Font size of strip text. Ignored if size_theme not NULL.

title_size

Font size of plot title. Ignored if size_theme not NULL.

...

Additional arguments to pass to ggplot2::theme()

Value

A ggplot2::theme() object.

Examples

require(ggplot2)
ggplot(iris) +
  aes(x = Sepal.Length, y = Sepal.Width) +
  geom_point() +
  theme_vmodern()