Plot kernel density estimates of a continuous variable faceted by the analysis number.

# S3 method for data.frame
plot_density(data, var, xlim = NULL)

Arguments

data

A dataset returned by ecdata::pin_nsclc() and preprocessed using preprocess().

var

A character vector of length 1 indicating the variable to plot.

xlim

Limits for the x-axis passed to ggplot2::coord_cartesian().

Value

A ggplot2::ggplot object.