powered by
Create two Directed Acyclic Graphs (DAGs), before and after conditioning on the collider M, for selection bias caused by M bias, using 'ggdag'.
# S3 method for mbias plot(x, type = c("before", "after"), dec = 2, ...)
A DAG for selection bias caused by M bias.
'mbias' object to plot.
DAG before or after conditioning on M.
Number of digits displayed.
Other unused arguments.
mbias
plot(mbias(or = c(2, 5.4, 2.5, 1.5, 1), var = c("HIV", "Circumcision", "Muslim", "Low CD4", "Participation")))
Run the code above in your browser using DataLab