Testing graphical causal models using the R package “dagitty”
Open accessAbstract
Causal diagrams such as directed acyclic graphs (DAGs) are used in several scientific fields to help design and analyze studies that aim to infer causal effects from observational data; for example, DAGs can help identify suitable strategies to reduce confounding bias. However, DAGs can be difficult to design, and the validity of any DAG-derived strategy hinges on the validity of the postulated DAG itself. Researchers should therefore check whether the assumptions encoded in the DAG are consistent with the data before proceeding with the analysis. Here, we explain how the R package 'dagitty', based on the web tool dagitty.net, can be used to test the statistical implications of the assumptions encoded in a given DAG. We hope that this will help researchers discover model specification errors, avoid erroneous conclusions, and build better models. © 2021 The Authors. Basic Protocol 1: Constructing and importing DAG models from the dagitty web interface Support Protocol 1: Installing R, RStudio, and the dagitty package Basic Protocol 2: Testing DAGs against categorical data Basic Protocol 3: Testing DAGs against continuous data Support Protocol 2: Testing DAGs against continuous data with non-linearities Basic Protocol 4: Testing DAGs against a combination of categorical and continuous data.
The claims and statistics of this paper haven’t been checked yet.
Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.
Integrity signals
Registry
Cites
Statistics
Claims the paper makes
The claims and statistics of this paper haven’t been checked yet.
Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.
Claims other papers make about this one
Each is checked against this paper’s own text: does it say what the citing paper says it does?
To facilitate causal inference, a directed acyclic graph (DAG), constructed using dagitty, was used for model selection.
“To facilitate causal inference, we used a directed acyclic graph (DAG), constructed using dagitty (Ankan et al., 2021), for model selection (Fig. S1).”
From Abandoning female genital mutilation/cutting (FGMC) is an emerging but costly parental investment strategy in rural Ethiopia. (2023) · cites this paper as Ankan et al., 2021
Self-check
Percentages, sums and reported differences re-computed from the paper’s own numbers.
The self-check needs the paper’s full text.
Cites
Robust Locally Weighted Regression and Smoothing Scatterplots
Cleveland, W. S. (1979) · Journal of the American Statistical Association · doi:10.1080/01621459.1979.10481038 · Cited by 11,594 · see citing works
Robust causal inference using directed acyclic graphs: the R package ‘dagitty’
Textor, J., van der Zander, B., Gilthorpe, M. S., Liśkiewicz, M., & Ellison, G. T. H. (2017) · International Journal of Epidemiology · doi:10.1093/ije/dyw341 · Cited by 2,295 · see citing works
Self-citationCausal Protein-Signaling Networks Derived from Multiparameter Single-Cell Data
Sachs, K., Perez, O. D., Pe’er, D., Lauffenburger, D. A., & Nolan, G. P. (2005) · Science · doi:10.1126/science.1105809 · Cited by 1,724 · see citing works
Causal Inference in Statistics
Pearl, J., Glymour, M., & Jewell, N. P. (2016) · Cited by 1,436 · see citing works
Scaling up the accuracy of Naive-Bayes classifiers: a decision-tree hybrid
Kohavi, R. (1996) · Cited by 1,404 · see citing works
Textor, J. C., Hardt, J., & Knüppel, S. (2011) · Epidemiology · doi:10.1097/ede.0b013e318225c2be · Cited by 1,227 · see citing works
Self-citationTennant, P. W. G., Murray, E. J., Arnold, K. F., Berrie, L., Fox, M. P., Gadd, S. C., Harrison, W. J., Keeble, C. M., Ranker, L. R., Textor, J. C., et al. (2020) · International Journal of Epidemiology · doi:10.1093/ije/dyaa213 · Cited by 1,065 · see citing works
Self-citationPearson, K. (1900) · Philosophical Transactions of the Royal Society of London Series A Containing Papers of a Mathematical or Physical Character · doi:10.1098/rsta.1900.0022 · Cited by 486 · see citing works
Parks, D. R., Roederer, M., & Moore, W. (2006) · Cytometry Part A · doi:10.1002/cyto.a.20258 · Cited by 246 · see citing works
Invariant Causal Prediction for Nonlinear Models
Heinze‐Deml, C., Peters, J., & Meinshausen, N. (2018) · Journal of Causal Inference · doi:10.1515/jci-2017-0016 · Cited by 198 · see citing works
Local fit evaluation of structural equation models using graphical criteria.
Thoemmes, F. J., Rosseel, Y., & Textor, J. C. (2017) · Psychological Methods · doi:10.1037/met0000147 · Cited by 70 · see citing works
Self-citation
Flagged first, then by citations
Research works printed but not linked: 1
- Pearl, J., & Mackenzie, D. (2018). The book of why. New York: Basic Books. ISBN 978-0-465- 09760-9. · DOI
Cited by
Sorted by citations
Gibson, M. A., Gurmu, E., Chua, R., Van Bavel, H., & Myers, S. (2023) · Social Science & Medicine · doi:10.1016/j.socscimed.2023.116170 · Cited by 11 · see citing works
- Authors
- Ankan, A., Wortel, I. M. N., & Textor, J.
- Affiliations
- Radboud University Nijmegen (NL)
- Corresponding author
- Textor, Johannes
- Venue
- Current Protocols
- Publisher
- Wiley
- Published
- 2021-02
- Volume
- 1
- Issue
- 2
- Pages
- e45-e45
- ISSN
- 2691-1299 (ISSN-L)
- OpenAlex
- W3131826007
- Cited by
- 86
- References
- 11
- Citations by year
- 2026: 13 · 2025: 15 · 2024: 20 · 2023: 21 · 2022: 16 · 2021: 1
- FWCI
- 11.00
- Type
- journal article
- Language
- en
- Open access
- hybrid
- doi.org
- Licence
- Locations
- Current Protocols (publishedVersion, cc-by)
- PubMed (publishedVersion)
- Radboud Repository (Radboud University) (submittedVersion)
- Radboud Repository (Radboud University) (submittedVersion, other-oa)
- Funders
- Radboud Universitair Medisch Centrum
- Kurt Weill Foundation for Music
- Topics
- Physical Sciences › Mathematics › Statistics and Probability › Advanced Causal Inference Techniques
- Physical Sciences › Computer Science › Artificial Intelligence › Bayesian Modeling and Causal Inference
- Social Sciences › Arts and Humanities › History and Philosophy of Science › Philosophy and History of Science
- Keywords
- causal graphical models, directed acyclic graphs, causal inference, specification testing, confounding, observational data, nonlinear relationship
- MeSH terms
- Data Interpretation, Statistical, Models, Theoretical, Bias, Causality, Confounding Factors, Epidemiologic
About these checks
Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.
Statistics and arithmetic are recomputed, not judged.
Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.
What counts as a claim ›How we measure confidence ›How we check this ›
Are you an author, or do you see a problem with this page? Request a review