pcalg (version 2.6-7)

pcAlgo: PC-Algorithm [OLD]: Estimate Skeleton or Equivalence Class of a DAG

Description

This function is DEPRECATED! Use skeleton, pc or fci instead.

Use the PC-algorithm to estimate the underlying graph (“skeleton”) or the equivalence class (CPDAG) of a DAG.

Usage

pcAlgo(dm = NA, C = NA, n=NA, alpha, corMethod = "standard",
       verbose=FALSE, directed=FALSE, G=NULL, datatype = "continuous",
       NAdelete=TRUE, m.max=Inf, u2pd = "rand", psepset=FALSE)

Arguments

dm

Data matrix; rows correspond to samples, cols correspond to nodes.

C

Correlation matrix; this is an alternative for specifying the data matrix.

n

Sample size; this is only needed if the data matrix is not provided.

alpha

Significance level for the individual partial correlation tests.

corMethod

A character string speciyfing the method for (partial) correlation estimation. "standard", "QnStable", "Qn" or "ogkQn" for standard and robust (based on the Qn scale estimator without and with OGK) correlation estimation. For robust estimation, we recommend "QnStable".

verbose

0-no output, 1-small output, 2-details;using 1 and 2 makes the function very much slower

directed

If FALSE, the underlying skeleton is computed; if TRUE, the underlying CPDAG is computed

G

The adjacency matrix of the graph from which the algorithm should start (logical)

datatype

Distinguish between discrete and continuous data

NAdelete

Delete edge if pval=NA (for discrete data)

m.max

Maximal size of conditioning set

u2pd

Function used for converting skeleton to cpdag. "rand" (use udag2pdag); "relaxed" (use udag2pdagRelaxed); "retry" (use udag2pdagSpecial)

psepset

If true, also possible separation sets are tested.

Value

An object of class "pcAlgo" (see '>pcAlgo) containing an undirected graph (object of class "graph", see graph-class from the package graph) (without weigths) as estimate of the skeleton or the CPDAG of the underlying DAG.

References

P. Spirtes, C. Glymour and R. Scheines (2000) Causation, Prediction, and Search, 2nd edition, The MIT Press.

Kalisch M. and P. B\"uhlmann (2007) Estimating high-dimensional directed acyclic graphs with the PC-algorithm; JMLR, Vol. 8, 613-636, 2007.