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 pcalg::skeleton() for details.

type

Character string specifying the version of the FCI algorithm to be used. See pcalg::fci() for details.

fixedGaps

See pcalg::fci() for details.

fixedEdges

See pcalg::fci() for details.

NAdelete

See pcalg::fci() for details.

m.max

Maximum size of the conditioning sets that are considered in the conditional independence tests.

pdsep.max

See pcalg::fci() for details.

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 pcalg::fci() for details.

biCC

See pcalg::fci() for details.

conservative

See pcalg::fci() for details.

maj.rule

See pcalg::fci() for details.

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)



[Package micd version 1.1.1 Index]