Sebastian Sauer

August 30, 2016

Reading time ~1 minute

Plotting a normal distribution is something needed in a variety of situation: Explaining to students (or professors) the basic of statistics; convincing your clients that a t-Test is (not) the right approach to the problem, or pondering on the vicissitudes of life…

If you like ggplot2, you may have wondered what the easiest way is to plot a normal curve with ggplot2?

Here is one:

library(cowplot)

## Loading required package: ggplot2

##
## Attaching package: 'cowplot'

## The following object is masked from 'package:ggplot2':
##
## ggsave

Note that cowplot here is optional, and gives a more “clean” appearance to the plot. Without cowplot, ie., the standard theme of ggplot2, you will get (better restart your R session before running the next code):