Skip to contents

Plotting densities of observed and imputed data points.

Usage

plot_points_density(dat, dat_imputed, variable = colnames(dat)[1])

Arguments

dat

a data.frame containing missing values denoted by NA.

dat_imputed

imputed dataset containing no NAs.

variable

a character name of a variable. Should be contained in both dat and dat_imputed. Default to first variable from the data.

Value

A ggplot2 object.

Examples

data(sim_miss_large)
sim_miss_large_imputed <- impute_knn(sim_miss_large)
plot_points_density(sim_miss_large, sim_miss_large_imputed)