scale_fill_sanger: Branded discrete colour scale

View source: R/scale_fill_sanger.R

scale_fill_sangerR Documentation

Branded discrete colour scale

Description

This anonymous function allows you to apply the Sanger Theme colours to your ggplot2 plot

Usage

scale_fill_sanger()

Value

A custom colour filled ggplot2 plot

Examples

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()

ald0405/SangerTools documentation built on Feb. 20, 2024, 3:11 p.m.