theme_qcc {industRial}R Documentation

Custom theme "qcc" for the book industRial Data Science plots

Description

This theme provides a similar look and feel to the package qcc statistical process control charts (SPC) which have themselves a resemblance with Minitab charts. This theme aims at providing a layout that is familiar to readers of Minitab chart to help in reducing transition to R build reports and charts.

Usage

theme_qcc(base_size = 12, base_family = "")

Arguments

base_size

font size, defaults to 12

base_family

font family defaults to ""

Details

Apply this theme by adding it at the end of the code of any ggplot chart. It #' basically provides a grey background and some highlights to help reading key process statistics such as the population mean.

Value

This function returns an object of classes theme and gg from the ggplot2 package

References

For a complete case study application refer to https://j-ramalho.github.io/industRial/

Examples

library(dplyr)
library(ggplot2)

pet_delivery %>% 
   ggplot(aes(x = A)) +
   geom_histogram(color = "grey", fill = "grey90") +
   labs(title = "PET clothing case study",
      subtitle = "Raw data plot",
      x = "Treatment",
      y = "Tensile strength [MPa]") +
      theme_qcc()

[Package industRial version 0.1.0 Index]