powered by
Evaluate an R expression in the environments constructed from the imputed data sets of a call to amelia function.
amelia
# S3 method for amelia with(data, expr, ...)
a list the same length as data$imputations that contains the output of the expression as evaluated in each imputed data set of data.
data$imputations
data
imputation output from the amelia funtion.
expression to evaluate in each imputed data set in data.
arguments to be passed to (future) methods.
Matt Blackwell
data(africa) a.out <- amelia(x = africa, cs = "country", ts = "year", logs = "gdp_pc") imp.mods <- with(a.out, lm(gdp_pc ~ infl + trade)) mi.combine(imp.mods, conf.int = TRUE)
Run the code above in your browser using DataLab