norm_dist_plot: Create density histogram with normal distribution overlaid

Description Usage Arguments Value Examples

View source: R/norm_dist_plot.R

Description

Plots a simple density histogram for a continuous variable with a normal distribution overlaid. The overlaid normal distribution has the same mean and standard deviation as the provided variable, and the plot provides a visual means to assess the normality of the variable's distribution.

Usage

1

Arguments

df

A data.frame or tibble.

vars

A character vector of continuous variable names.

Value

A ggplot object.

Examples

1
2
3
4
norm_dist_plot(df = iris, vars = "Sepal.Width")

norm_dist_plot(df = iris,
               vars = c("Sepal.Width", "Sepal.Length"))

craigjmcgowan/describedata documentation built on Aug. 25, 2020, 10:45 a.m.