#' ggplot theme for package
#'
#' @description A standard theme to use for plots generated by this package
#'
#' @param base_size base font size, given in pts.
#' @param base_family base font family
#' @param aspect_square set aspect.ratio to 1
#' @param border include a border
#'
#' @return theme
#' @export
#'
theme_camprot <- function(base_size=20, base_family='serif',
aspect_square=TRUE, border=TRUE){
camprot_theme <- theme_bw(base_size=base_size,
base_family=base_family) +
theme(panel.grid=element_blank(),
panel.background = element_blank())
if(aspect_square){
camprot_theme <- camprot_theme + theme(aspect.ratio=1)
}
if(!border){
camprot_theme <- camprot_theme + theme(
panel.border = element_blank(),
axis.line = element_line(colour = "black", linewidth=0.5))
}
camprot_theme
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.