Plot bootstrap results when utilizing model selection/averaging after multiple imputation

Share:

Description

Plots the bootstrap distribution of model selection/averaging estimators after multiple imputation. By default, the areas of the boostrap distribution that are left and right of zero are shaded in different colors to better identify the importance of each variable.

Usage

1
2
3
## S3 method for class 'mami'
plot(x, shade.areas = TRUE, plots.p.page = c("1", "4", "9", "16"), 
color = c("lightgrey", "darkgrey"), adj.bw = 1, ...)

Arguments

x

An object of class "mami".

shade.areas

A logical value indicating whether areas left and right of zero should be shaded or not.

plots.p.page

A string of either "1", "4", "9", or "16" indicating the number of plots per page.

color

A string vector of length 2 indicating the colors used for the shaded areas.

adj.bw

An integer to adjust the bandwidth.

...

Further graphical arguments to be passed.

Author(s)

Michael Schomaker

Examples

1
2
3
4
5
6
7
8
9
library(Amelia)
data(freetrade)
freetrade$pop <- log(freetrade$pop) # in line with original publication
freetrade_imp <- amelia(freetrade, ts = "year", cs = "country", noms="signed", polytime = 2,
                        intercs = TRUE, empri = 2)
m1 <- mami(freetrade_imp, method="criterion.selection", ycol="tariff",add.factor=c("country"),
           inference="+bootstrapping", B=25,X.org=freetrade,print.time=TRUE)
m1 # be patient with bootstrapping, increase B>=200 for better results
plot(m1)