theme_csd: Charlotte's ggplot2 theme

View source: R/theme_csd.R

theme_csdR Documentation

Charlotte's ggplot2 theme

Description

A standard theme to use for plots generated by this package.

Usage

theme_csd(
  base_size = 14,
  base_family = "sans",
  base_line_size = base_size/18,
  base_rect_size = base_size/9,
  aspect_square = TRUE,
  border = TRUE
)

Arguments

base_size

numeric. Defines the overall size of the plot.

base_family

string. Fontfamily to use, default is "sans".

base_line_size

numeric. Defines the line size to use.

base_rect_size

numeric. Defines the rect size to use.

aspect_square

logical. Should a square aspect ratio be used? Default is TRUE.

border

logical. Should the plot have a square border? Default is TRUE.

Value

Returns a theme object.

Examples

set.seed(11)
library(ggplot2)

df <- diamonds[sample(nrow(diamonds), 1000), ]

ggplot(df, aes(x = price, y = carat)) +
  geom_point() +
  theme_csd()


CambridgeCentreForProteomics/camprotR documentation built on Jan. 27, 2023, 8:36 p.m.