theme_NCStats: A ggplot2 theme.

Description Usage Arguments Value Examples

View source: R/misc-utils.R

Description

A basic ggplot2 theme for use in statistics courses at Northland College.

Usage

1
2
3
4
5
6
theme_NCStats(
  base_size = 12,
  base_family = "",
  base_line_size = base_size/24,
  base_rect_size = base_size/24
)

Arguments

base_size

The base font size.

base_family

The base font family.

base_line_size

The base size for line elements.

base_rect_size

The base size for rect elements.

Value

A function that will apply a theme to a ggplot2 object.

Examples

1
2
3
4
5
6
p <- ggplot2::ggplot(data=data.frame(x=c(1,2,3,1,3,1),
                                     y=c(1,3,1,2.3,2.3,1)),
                     mapping=ggplot2::aes(x=x,y=y)) +
  ggplot2::geom_polygon()
p
p + theme_NCStats()

droglenc/NCStats documentation built on June 5, 2021, 2:06 p.m.