After using the MICE package to impute missing data I am looking for a way to plot the distribution, using a histogram, of one of the imputed variables. I can use the following code to plot the distribution of "Ozone", however one histogram per imputed dataset (5 in total) is produced.
I am looking for a way to create 1 histogram which is the "pooled" result of the 5 histograms, if this is possible. Similar to how you would pool regression coefficients from MICE imputed datasets to get a final summary for the coefficients.
# Example dataset
data <- airquality
# Add missing data
data[4:10,3] <- rep(NA,7)
data[1:5,4] <- NA
data <- data[-c(5,6)]
# Impute missing data creating 5 datasets
imp <- mice::mice(data,m=5,maxit=50,meth='pmm',seed=500)
# Plot distribution of "Ozone" - Results in 5 plots, Aim is one "pooled" histogram
with(imp, hist(Ozone))
