theme_ggEHD: DeLucia lab ggplot2 theme

Description Usage Arguments Value Author(s) See Also Examples

View source: R/theme_ggEHD.R

Description

Style ggpplot2 elements to provide the format Evan most commonly requests. Actual Evan-approval of the result is not guaranteed.

Usage

1
	theme_ggEHD(base_size=18, base_family="")

Arguments

base_size

Base font size for the theme, in points.

base_family

Font family to use in element_text.

Value

a complete theme based on theme_bw.

Author(s)

Chris Black <chris@ckblack.org>

See Also

theme for a list of the possible theme elements; the ggplot2 themes vignette for details on using the theme system.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
library(ggplot2)

carplot = (ggplot(mtcars, aes(wt, mpg))
	+geom_smooth(method="lm", linetype="dotted")
	+geom_point()
	+xlab("Vehicle weight (k lb)")
	+ylab("MPG"))

# Ideal base_size will differ depending on your target resolution.
carplot_screen = carplot + theme_ggEHD(12)
carplot_poster = carplot + theme_ggEHD(32)

# Adding theme_ggEHD() replaces all existing theme information.
# To alter theme elements, add them downstream of theme_ggEHD.
carplot_stretched = carplot + theme_ggEHD(12) + theme(aspect.ratio=0.25)

infotroph/DeLuciatoR documentation built on May 30, 2020, 10:28 p.m.