Histograms and Density Plots in ggplot2

Change histogram plot colors by groups:

The following sections describe:

  • Calculating the mean of each group
  • Changing line color
  • Changing fill color