Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
. 2023 Oct 5;52(5):1659-1664.
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

Affiliations

Software Application Profile: The daggle app-a tool to support learning and teaching the graphical rules of selecting adjustment variables using directed acyclic graphs

Mark Hanly et al. Int J Epidemiol. .

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.

PubMed Disclaimer

Conflict of interest statement

None declared.

Figures

Figure 1
Figure 1
An example directed acyclic graph (DAG)
Figure 2
Figure 2
Examples of open and closed paths, and the effect of conditioning in three different scenarios
Figure 3
Figure 3
A screenshot of the daggle app in random mode, with variables Z2 and Z3 selected for adjustment. Try to solve this daggle at [cbdrh.shinyapps.io/daggle/?_values_&id=145590]

Similar articles

Cited by

References

    1. Pearl J. Causal diagrams for empirical research. Biometrika 1995;82:669–88.
    1. Greenland S, Pearl J, Robins JM.. Causal diagrams for epidemiologic research. Epidemiology 1999;37–48. - PubMed
    1. Austin AE, Desrosiers TA, Shanahan ME.. Directed acyclic graphs: an under-utilized tool for child maltreatment research. Child Abuse Negl 2019;91:78–87. - PMC - PubMed
    1. VanderWeele TJ. Principles of confounder selection. Eur J Epidemiol 2019;34:211–19. - PMC - PubMed
    1. Etminan M, Collins GS, Mansournia MA.. Using causal diagrams to improve the design and interpretation of medical research. Chest 2020;158:S21–28. - PubMed