gg_groupplot: Create ggplot to display group differences (box+point+hist)
Description
The gg_groupplot function can be used to create group
difference plots for scientific publication.
This is intended to summarize a continuous outcome (y)
based on a factor ('x') from an input dataset (data).
The plot will include standard ggplot2::geom_boxplot
indicating 25th, median, and 75th percentile for the box
and 1.5 * IQR for the whiskers. Outliers are not
highlighted.
Raw data is displayed with standard ggplot2::geom_point
and lateral but not vertical jittering.
Histograms are shown with half_violin
to the right of each boxplot.
If meanline = = TRUE (default), gray dots will indicate
the mean for each variable (vs. median in boxplot)
connected by a gray line.
This function will drop any NA values.
Requires ggplot2 and ggdist libraries.