View source: R/scale_fill_sanger.R
scale_fill_sanger | R Documentation |
This anonymous function allows you to apply the Sanger Theme colours to your ggplot2 plot
scale_fill_sanger()
A custom colour filled ggplot2 plot
library(SangerTools) library(dplyr) library(ggplot2) # Group by Age Band health_data <- SangerTools::PopHealthData health_data %>% dplyr::filter(Smoker == 1) %>% SangerTools::categorical_col_chart(AgeBand) + labs( title = "Smoking Population by Age Band", subtitle = "Majority of Smokers are Working Aged ", x = NULL, y = "Patient Number" )+ scale_fill_sanger()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.