From ab62b54925c714f5b79b392c3cda5bc31bb9d0e7 Mon Sep 17 00:00:00 2001 From: Nina Zumel Date: Wed, 9 Oct 2019 17:14:24 -0700 Subject: [PATCH] changed density plot to filled for Normal plot --- R/DistributionPlot.R | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/R/DistributionPlot.R b/R/DistributionPlot.R index ce20d42..1b43911 100644 --- a/R/DistributionPlot.R +++ b/R/DistributionPlot.R @@ -31,7 +31,7 @@ NULL #' @export PlotDistDensityNormal <- function(frm, xvar, title, ..., adjust = 0.5, - curve_color = 'black', + curve_color = 'lightgray', normal_color = 'blue', mean_color = 'blue', sd_color = 'darkgray') { @@ -55,7 +55,8 @@ PlotDistDensityNormal <- function(frm, xvar, title, ..., plt = ggplot2::ggplot() + ggplot2::geom_density(data=dPlot, mapping=ggplot2::aes_string(x=xvar), - color = curve_color, + fill = curve_color, + color = NA, adjust=adjust) + ggplot2::geom_line(data=dDist, mapping=ggplot2::aes_string(x=xvar,y='density'),