instrumentalVariables: Find Instrumental Variables

Description Usage Arguments References Examples

Description

Generates a list of instrumental variables that can be used to infer the total effect of an exposure on an outcome in the presence of latent confounding, under linearity assumptions.

Usage

1
instrumentalVariables(x, exposure = NULL, outcome = NULL)

Arguments

x

the input graph, a DAG.

exposure

name of the exposure variable. If not given (default), then the exposure variable is supposed to be defined in the graph itself. Only a single exposure variable and a single outcome variable supported.

outcome

name of the outcome variable, also taken from the graph if not given. Only a single outcome variable is supported.

References

B. van der Zander, J. Textor and M. Liskiewicz (2015), Efficiently Finding Conditional Instruments for Causal Inference. In Proceedings of the 24th International Joint Conference on Artificial Intelligence (IJCAI 2015), pp. 3243-3249. AAAI Press, 2015.

Examples

1
2
3
4
# The classic IV model
instrumentalVariables( "dag{ i->x->y; x<->y }", "x", "y" )
# A conditional instrumental variable
instrumentalVariables( "dag{ i->x->y; x<->y ; y<-z->i }", "x", "y" )


Search within the dagitty package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.