Bayesian prediction models for cardiometabolic disease (CMD) using data from the SCAPIS cohort. Current pipeline version: v07.
cmdpredict_bayesian/
├── Main analysis/ # Steps 1-5: the primary pipeline
├── Stepwise/ # Nested/domain models (m1-m9)
├── Interaction/ # Interaction-term models (5 pairs)
└── Stan/ # Stan model files
Start in Main analysis/. Stepwise/ and Interaction/ reuse the data and fold indices created by Main analysis/ Step 1, so run that first. See the README in each subfolder.
cmdpredict_{step}_logit({any|multi})[_{variant}]_v{version}.R
{step} — position in the analysis pipeline:
| Step | Meaning |
|---|---|
1 |
Pre-processing and 10-fold CV split |
2 |
Model fitting across folds |
3 |
Results compilation |
4 |
Full-sample fitting and individual predictions |
5 |
Subgroup analysis |
logit({any|multi}) — outcome:
| Tag | Outcome |
|---|---|
logit(any) |
cmd_any — any cardiometabolic disease (no CMD vs any CMD) |
logit(multi) |
cmd_multi — cardiometabolic multimorbidity (no CMD multimorbidity vs CMD multimorbidity) |
{variant} — present only in the Stepwise/ and Interaction/ folders:
| Tag | Meaning |
|---|---|
m1-m9 |
Nested/domain model set (see Stepwise/) |
interaction / interactions |
Interaction-term models (see Interaction/) |
Other tags appearing in script and output file names:
| Tag | Meaning |
|---|---|
cov |
Complete-case analysis |
lasso |
Regularised model |
cvresult |
Cross-validated fold results |
Examples:
Main analysis/cmdpredict_2_logit(any)_v07.R— Step 2,cmd_anyStepwise/cmdpredict_2_logit(multi)_m1-m9_v07.R— Step 2,cmd_multi, models m1–m9Interaction/cmdpredict_3_logit(any)_interactions_v07.R— Step 3,cmd_any, interaction models