Learn R Programming

⚠️There's a newer version (2.7-12) of this package.Take me there.

pcalg (version 2.2-3)

Methods for Graphical Models and Causal Inference

Description

Functions for causal structure learning and causal inference using graphical models. The main algorithms for causal structure learning are PC (for observational data without hidden variables), FCI and RFCI (for observational data with hidden variables), and GIES (for a mix of data from observational studies (i.e. observational data) and data from experiments involving interventions (i.e. interventional data) without hidden variables). For causal inference the IDA algorithm, the Generalized Backdoor Criterion (GBC) and the Generalized Adjustment Criterion (GAC) are implemented.

Copy Link

Version

Install

install.packages('pcalg')

Monthly Downloads

1,818

Version

2.2-3

License

GPL (>= 2)

Maintainer

Markus Kalisch

Last Published

July 12th, 2015

Functions in pcalg (2.2-3)

gAlgo-class

Class "gAlgo"
GaussL0penObsScore-class

Class "GaussL0penObsScore"
gmI

Graphical Model 7-dim IDA Data Examples
dsepTest

Test for d-separation in a DAG
pcalg-internal

Internal Pcalg Functions
gmB

Graphical Model 5-Dim Binary Example Data
pc.cons.intern

Utility for conservative and majority rule in PC and FCI
ges

Estimate the Markov equivalence class of a DAG using GES
EssGraph-class

Class "EssGraph"
compareGraphs

Compare two graphs in terms of TPR, FPR and TDR
pcSelect

PC-Select: Estimate subgraph around a response variable
ParDAG-class

Class "ParDAG"
gds

Greedy DAG Search to Estimate Markov Equivalence Class of DAG
Score-class

Virtual Class "Score"
GaussParDAG-class

Class "GaussParDAG"
condIndFisherZ

Test Conditional Independence of Gaussians via Fisher's Z
backdoor

Find Set Satisfying the Generalized Backdoor Criterion
getNextSet

Iteration through a list of all combinations of choose(n,k)
gmInt

Graphical Model 8-Dimensional Interventional Gaussian Example Data
rfci

Estimate an RFCI-PAG using the RFCI Algorithm
mat2targets

Construct a list of intervention targets and a target index vector
dag2essgraph

Convert a DAG to an Essential Graph
fci

Estimate a PAG by the FCI Algorithm
randDAG

Random DAG Generation
legal.path

Check if a 3-node-path is Legal
fciPlus

Estimate a PAG by the FCI+ Algorithm
disCItest

G square Test for (conditional) Independence for Discrete Data
gies

Estimate Interventional Markov Equivalence Class of a DAG by GIES
mcor

Compute (Large) Correlation Matrix
pcAlgo-class

Class "pcAlgo"
checkTriple

Check Consistency of Conditional Independence for a Triple of Nodes
pdsep

Estimate Final Skeleton in the FCI algorithm
dreach

Compute D-SEP(x,y,G)
pcorOrder

Compute Partial Correlations
corGraph

Computing the correlation graph
pc

Estimate the Equivalence Class of a DAG using the PC Algorithm
pcSelect.presel

Estimate Subgraph around a Response Variable using Preselection
r.gauss.pardag

Generate a Gaussian Causal Model Randomly
pdag2dag

Extend a Partially Directed Acyclic Graph (PDAG) to a DAG
plotAG

Plot partial ancestral graphs (PAG)
visibleEdge

Check visible edge.
beta.special.pcObj

Compute set of intervention effects in a fast way
beta.special

Compute set of intervention effects
skeleton

Estimate (Initial) Skeleton of a DAG using the PC / PC-Stable Algorithm
getGraph

Get the "graph" Part or Aspect of R Object
pag2mag

Transform a PAG into a MAG in the Corresponding Markov Equivalence Class
dag2pag

Convert a DAG with latent variables into a PAG
dsep

Test for d-separation in a DAG
simy

Estimate Interventional Markov Equivalence Class of a DAG
possibleDe

Find possible descendants on definite status paths.
binCItest

G square Test for (Conditional) Independence of Binary Variables
gmL

Latent Variable 4-Dim Graphical Model Data Example
showAmat

Show Adjacency Matrix of pcAlgo object
iplotPC

Plotting a pcAlgo object using the package igraph
udag2pdag

Last PC Algorithm Step: Extend Object with Skeleton to Completed PDAG
gmD

Graphical Model Discrete 5-Dim Example Data
qreach

Compute Possible-D-SEP(x,G) of a node x in a PDAG G
fciAlgo-class

Class "fciAlgo"
gmG

Graphical Model 8-Dimensional Gaussian Example Data
shd

Compute Structural Hamming Distance (SHD)
rmvDAG

Generate Multivariate Data according to a DAG
jointIda

Estimate Multiset of Possible Total Joint Effects
idaFast

Multiset of Possible Total Causal Effects for Several Target Var.s
randomDAG

Generate a Directed Acyclic Graph (DAG) randomly
udag2apag

Last step of RFCI algorithm: Transform partially oriented graph into RFCI-PAG
wgtMatrix

Compute weight matrix of simulated DAG.
ida

Estimate Multiset of Possible Total Causal Effects
LINGAM

Linear non-Gaussian Additive Models
udag2pag

Last steps of FCI algorithm: Transform Final Skeleton into FCI-PAG
showEdgeList

Show Edge List of pcAlgo object
rmvnorm.ivent

Simulate from a Gaussian Causal Model
Uniform DAG Sampling

Sample DAG uniformly
gac

Test If Set Satisfies Generalized Adjustment Criterion (GAC)
find.unsh.triple

Find all Unshielded Triples in an Undirected Graph
pcAlgo

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

Covariance matrix of a DAG.
GaussL0penIntScore-class

Class "GaussL0penIntScore"
dag2cpdag

Convert a DAG to a CPDAG
plotSG

Plot the subgraph around a Specific Node in a Graph Object