Software Application Profile: The daggle app-a tool to support learning and teaching the graphical rules of selecting adjustment variables using directed acyclic graphs
- PMID: 36952629
- PMCID: PMC10555701
- DOI: 10.1093/ije/dyad038
Software Application Profile: The daggle app-a tool to support learning and teaching the graphical rules of selecting adjustment variables using directed acyclic graphs
Abstract
Motivation: Directed acyclic graphs (DAGs) are used in epidemiological research to communicate causal assumptions and guide the selection of covariate adjustment sets when estimating causal effects. For any given DAG, a set of graphical rules can be applied to identify minimally sufficient adjustment sets that can be used to adjust for bias due to confounding when estimating the causal effect of an exposure on an outcome. The daggle app is a web-based application that aims to assist in the learning and teaching of adjustment set identification using DAGs.
General features: The application offers two modes: tutorial and random. The tutorial mode presents a guided introduction to how common causal structures can be presented using DAGs and how graphical rules can be used to identify minimally sufficient adjustment sets for causal estimation. The random mode tests this understanding by presenting the user with a randomly generated DAG-a daggle. To solve the daggle, users must correctly identify a valid minimally sufficient adjustment set.
Implementation: The daggle app is implemented as an R shiny application using the golem framework. The application builds upon existing R libraries including pcalg to generate reproducible random DAGs, dagitty to identify all valid minimal adjustment sets and ggdag to visualize DAGs.
Availability: The daggle app can be accessed online at [http://cbdrh.shinyapps.io/daggle]. The source code is available on GitHub [https://github.com/CBDRH/daggle] and is released under a Creative Commons CC BY-NC-SA 4.0 licence.
Keywords: Directed acyclic graphs; confounding adjustment; teaching.
© The Author(s) 2023. Published by Oxford University Press on behalf of the International Epidemiological Association.
Conflict of interest statement
None declared.
Figures



Similar articles
-
Robust causal inference using directed acyclic graphs: the R package 'dagitty'.Int J Epidemiol. 2016 Dec 1;45(6):1887-1894. doi: 10.1093/ije/dyw341. Int J Epidemiol. 2016. PMID: 28089956
-
[Directed acyclic graphs (DAGs) - the application of causal diagrams in epidemiology].Gesundheitswesen. 2011 Dec;73(12):888-92. doi: 10.1055/s-0031-1291192. Epub 2011 Dec 22. Gesundheitswesen. 2011. PMID: 22193898 German.
-
Use of directed acyclic graphs (DAGs) to identify confounders in applied health research: review and recommendations.Int J Epidemiol. 2021 May 17;50(2):620-632. doi: 10.1093/ije/dyaa213. Int J Epidemiol. 2021. PMID: 33330936 Free PMC article. Review.
-
Combining directed acyclic graphs and the change-in-estimate procedure as a novel approach to adjustment-variable selection in epidemiology.BMC Med Res Methodol. 2012 Oct 11;12:156. doi: 10.1186/1471-2288-12-156. BMC Med Res Methodol. 2012. PMID: 23058038 Free PMC article.
-
Using directed acyclic graphs to guide analyses of neighbourhood health effects: an introduction.J Epidemiol Community Health. 2008 Sep;62(9):842-6. doi: 10.1136/jech.2007.067371. J Epidemiol Community Health. 2008. PMID: 18701738 Review.
Cited by
-
Calculating preventable risk fractions for exposure-reducing interventions.Glob Epidemiol. 2025 May 7;9:100206. doi: 10.1016/j.gloepi.2025.100206. eCollection 2025 Jun. Glob Epidemiol. 2025. PMID: 40496202 Free PMC article.
References
-
- Pearl J. Causal diagrams for empirical research. Biometrika 1995;82:669–88.
-
- Greenland S, Pearl J, Robins JM.. Causal diagrams for epidemiologic research. Epidemiology 1999;37–48. - PubMed
-
- Etminan M, Collins GS, Mansournia MA.. Using causal diagrams to improve the design and interpretation of medical research. Chest 2020;158:S21–28. - PubMed