Skip to content

Instantly share code, notes, and snippets.

View cgreene's full-sized avatar

Casey Greene cgreene

View GitHub Profile
@low-decarie
low-decarie / ggplot2 theme_minimal
Created May 4, 2012 13:58
ggplot2 theme_minimal
theme_minimal <- function (base_size = 12, base_family = "")
{
structure(list(axis.line = theme_blank(), axis.text.x = theme_text(family = base_family,
size = base_size * 0.8, lineheight = 0.9, vjust = 1),
axis.text.y = theme_text(family = base_family, size = base_size *
0.8, lineheight = 0.9, hjust = 1), axis.ticks = theme_segment(colour = "black",
size = 0.2), axis.title.x = theme_text(family = base_family,
size = base_size, vjust = 0), axis.title.y = theme_text(family = base_family,
size = base_size, angle = 90, vjust = 0.5), axis.ticks.length = unit(0.3,
"lines"), axis.ticks.margin = unit(0.5, "lines"), legend.background = theme_rect(colour = NA),