Learn R Programming

SciencesPo (version 1.4.0)

theme_fte: Themes for ggplot2 Graphs

Description

Theme for plotting with ggplot2.

Usage

theme_fte(legend = "none", legend_title = FALSE, base_size = 12, horizontal = TRUE, base_family = "", colors = c("#F0F0F0", "#D9D9D9", "#60636A", "#525252"))

Arguments

legend
Enables to set legend position, default is "none".
legend_title
Will the legend have a title?, Default is FALSE.
base_size
Overall font size. Default is 13.
horizontal
Logical. Horizontal axis lines?
base_family
Default font family.
colors
Default colors used in the plot in the following order: background, lines, text, and title.

Value

The theme.

Examples

Run this code
qplot(1:10, (1:10)^3) + theme_fte()

# Easy to set different theme colors:
mycolors = c("#F2F1E8",  "#D2D2D2",  "#6E6E6E", "#6E6E6E")
qplot(1:10, (1:10)^3) +
 theme_fte(colors=mycolors) #ae8b38

mycolors = c("wheat",  "#C2AF8D",  "#8F6D2F", "darkred")
qplot(1:10, (1:10)^3) +
 theme_fte(colors=mycolors)

# Check that it is a complete theme
attr(theme_fte(), "complete")

Run the code above in your browser using DataLab