Code of the simulation study from the manuscript 'A comparison of full model specification and backward elimination of potential confounders when estimating marginal and conditional causal effects on binary outcomes from observational data'.
The R code in ./rcode/add-ons/poc performs a proof of concept simulation. The results are stored as .rds file in .data/poc/
The R code in /rcode/dgm/ can be used to generate the data and the R code in /rcode/sim/ can be used to run the simulation study. Data are saved as .rds files in /data/raw/.
The R code in ./rcode/visualisation/ creates figures depicting the results of the simulation study. The script produces .pdf files. The scripts uses the .rds files available in ./data/summarised/. The output of the script is saved in .results/figures/.
Attached packages: data.table [version 1.12.8] simsalapar [version 1.0-10] logistf [version 1.24] MASS [version 7.3-51.5]
.
├── .gitignore
├── CITATION.md
├── LICENSE.md
├── README.md
├── data
│ ├── diagnostics <- diagnostics of simulation output (experiment 2)
│ ├── poc <- datafiles generated by the proof-of-concept simulation (experiment 1)
│ ├── raw <- datafiles generated in simulation (experiment 2)
│ └── summarised <- summaries of raw data (experiment 2)
├── docs <- manuscript source, e.g., LaTeX, Markdown, etc.
├── results
│ ├── figures <- figures for the manuscript or reports
│ └── tables <- tables for the manuscript or reports
└── rcode <- source code for this project
├── add-ons <- script for proof-of-concept simulation (experiment 1), analytical supplementary file and CABG example
├── analyses <- helper scripts and script for main analysis in simulation study (experiment 2)
├── dgm <- scripts that define the dgm (experiment 2)
├── exe <- main script from which simulation is executed (experiment 2)
├── sim <- scripts used to run the simulation study (experiment 2)
├── sumsim <- scripts to summarise simulation output (experiment 2)
└── visualisation <- scripts for visualisation of simulation results (experiment 1 and 2)