fciMI {micd} | R Documentation |
Estimate a PAG by the FCI-MI Algorithm for Multiple Imputed Data Sets of Continuous Data
Description
This function is a modification of pcalg::fci()
to be used for multiple imputation.
Usage
fciMI(
data,
alpha,
labels,
p,
skel.method = c("stable", "original"),
type = c("normal", "anytime", "adaptive"),
fixedGaps = NULL,
fixedEdges = NULL,
NAdelete = TRUE,
m.max = Inf,
pdsep.max = Inf,
rules = rep(TRUE, 10),
doPdsep = TRUE,
biCC = FALSE,
conservative = FALSE,
maj.rule = FALSE,
verbose = FALSE
)
Arguments
data |
An object of type mids, which stands for 'multiply imputed data set', typically created by a call to function mice() |
alpha |
Significance level (number in (0,1) for the conditional independence tests |
labels |
(Optional) character vector of variable (or "node") names. Typically preferred to specifying p. |
p |
(Optional) number of variables (or nodes). May be specified if labels are not, in which case labels is set to 1:p. |
skel.method |
Character string specifying method; the default, "stable"
provides an order-independent skeleton, see |
type |
Character string specifying the version of the FCI algorithm to be used.
See |
fixedGaps |
See |
fixedEdges |
See |
NAdelete |
See |
m.max |
Maximum size of the conditioning sets that are considered in the conditional independence tests. |
pdsep.max |
See |
rules |
Logical vector of length 10 indicating which rules should be used when directing edges. The order of the rules is taken from Zhang (2008). |
doPdsep |
See |
biCC |
See |
conservative |
See |
maj.rule |
See |
verbose |
If true, more detailed output is provided. |
Value
See pcalg::fci()
for details.
Author(s)
Original code by Diego Colombo, Markus Kalisch, and Joris Mooij. Modifications by Ronja Foraita.
Examples
daten <- windspeed[,1]
for(i in 2:ncol(windspeed)) daten <- c(daten, windspeed[,i])
daten[sample(1:length(daten), 260)] <- NA
daten <- matrix(daten, ncol = 6)
## Impute missing values
imp <- mice(daten, printFlag = FALSE)
fc.res <- fciMI(data = imp, label = colnames(imp$data), alpha = 0.01)
if (requireNamespace("Rgraphviz", quietly = TRUE))
plot(fc.res)