theme_gouv_map | R Documentation |
ggplot2 theme for map with French government design template
theme_gouv_map(
base_family = "Marianne",
base_size = 12,
plot_title_family = "Marianne",
plot_title_size = 28,
plot_title_face = "bold",
plot_title_margin = 10,
subtitle_family = "Marianne Light",
subtitle_size = 22,
subtitle_face = "plain",
subtitle_margin = 15,
strip_text_family = base_family,
strip_text_size = 14,
strip_text_face = "plain",
strip_text_color = "black",
strip_background_color = "#FFFFFF",
caption_family = base_family,
caption_size = 12,
caption_face = "plain",
caption_margin = 10,
plot_margin = margin(30, 30, 30, 30),
legend_background_color = "#FFFFFF",
legend_border_color = "#FFFFFF"
)
base_family, base_size |
Base font family and size. |
plot_title_family, plot_title_face, plot_title_size, plot_title_margin |
Plot title family, face, size and margin. |
subtitle_family, subtitle_face, subtitle_size |
Plot subtitle family, face and size. |
subtitle_margin |
Plot subtitle margin bottom (single numeric value). |
strip_text_family, strip_text_face, strip_text_size, strip_text_color |
Facet label font family, face, size and color. |
strip_background_color |
Facel label background color. |
caption_family, caption_face, caption_size, caption_margin |
Plot caption family, face, size and margin. |
plot_margin |
Plot margin (specify with |
legend_background_color |
Legend background fill color; default to |
legend_border_color |
Legend border color; default to |
This theme is designed for making map with ggplot plot with ggplot2::geom_sf()
.
All font sizes are set in points and colors are either a color name or a hex code.
A ggplot2
theme.
## Not run:
library(ggplot2)
library(sf)
demo(nc, ask = FALSE, echo = FALSE)
ggplot(data = nc) + geom_sf(aes(fill = BIR79)) + theme_gouv_map() +
scale_color_gouv_continuous() + labs(title = "North Carolina SIDS",
subtitle = "with theme_gouv_map()")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.