Skip to content

Instantly share code, notes, and snippets.

View dkcoxie's full-sized avatar

D. King dkcoxie

  • University of Michigan
View GitHub Profile
@benmarwick
benmarwick / 000_geom_bag.r
Last active January 5, 2025 01:16
Basic bagplot geom for ggplot2
#' Bagplot
#'
#' The bag geom is useful for graphical summaries of scatterplots. It
#' is effective at showing the location, spread, skewness, and
#' outliers of a data set.
#'
#' A bagplot is a bivariate generalization of the well known boxplot. It
#' was proposed by Rousseeuw, Ruts, and Tukey. This geom plots bagplots that
#' are very similar to the one described in Rousseeuw et al. and
#' uses code from their bagplot functions in the aplpack pacakge.