brms
3 posts
Mediation, confounding, and measurement error
In this post, I give a brief simulation-based example of how confounding and measurement error impacts the estimation of direct and indirect effects in a mediation analysis.
Estimating treatment effects and ICCs from (G)LMMs on the observed scale using Bayes, Part 1: lognormal models
In this post I show how to make marginal inferences on the untransformed scaled when using multilevel models with a non-linear transformation applied to the dependent variable (a log-transformation is used as an example). Cluster-specific versus population-average (conditional versus marginal) effects are compared using both average effects on the untransformed scale and using relative (multiplicative) effects.
Confounded dose-response effects of treatment adherence: fitting Bayesian instrumental variable models using brms
Non-randomized comparisons are common in RCTs. In this post I show some examples of confounding and collider bias, using treatment adherence as an example. I present a small simulation study that show that common regression models used in clinical psychology, makes little sense, and that Bayesian instrumental variable regression can be easily fit using the R package brms.