Monotone function estimation in the presence of extreme data coarsening: Analysis of preeclampsia and birth weight in urban Uganda.
This script runs the analysis in Monotone function estimation in the presence of extreme data coarsening: Analysis of preeclampsia and birth weight in urban Uganda (Starling et al., 2020). The script reproduces all figures and tables contained therein. Depends on the tsbart package, which is available using
library(devtools)
install_github('jestarling/tsbart')
Data file should be contained in a folder called data.
R scripts should be contained in a folder called code.
Note: Data for our application is not public; a toy file is included to show the data format, with observations generated by randomly generating from each column; this data will not replicate our figures. For all figures in Section 4, simulated data is generated in each R script.
The analysis can be replicated from within the project root directory by executing
bash_run_analysis.sh
The bash script performs the following steps:
-
- Creates an output directory.
-
- Runs the R script 01-sim-study-mse-inflation.R, creating Figures 2 and 3.
-
- Runs the R script 02-sim-study-monotonicity.R, creating Figure 4 and Table 2.
-
- Runs the R script 03-mulago-analysis.R, creating Figures 1, 5, 6, 7, 8, and Table 1.