Patterns for Bayesian inference in R using brms, including multilevel models, DAG validation, and marginal effects.
SkillScore77Maintained
Automatic
◆Data Analyst pack
Last verified 8/8/2026
What it changes
Passed 17 of 22 test cases with the skill, and 14 of 22 without it.
Without skill64%
With skill77%
Checks it passed that the model alone missed
Extracts Rhat from the model fixed summary.
Calculates probability by computing mean(diff > 0).
Extracts Bulk_ESS and Tail_ESS from the model fixed summary.
and 1 more in the full report
3 fixed14 passed either way5 still failing0 broke
Pass-rate lift
+14 pp
Tokens
+140%
Agent turns
0%
Response time
-16%
Model gemini-3.6-flashMeasured 8/8/2026v117 of 22 cases passed with skill
Tokens, turns and time describe resource use, not a dollar price.
See it in action
One of 3 test cases the skill fixed. Same model, same prompt, with and without the skill.
1 of 3
Prompt
I have already fitted a Bayesian logistic model using brms and now need to summarize and interpret the results. Could you provide R code that processes the posterior draws to calculate medians, 95% uncertainty intervals, and odds ratios, while also using marginaleffects to calculate average marginal slopes on the probability scale and predicted probabilities across standardized predictor levels (-1, 0, +1 SD) without random effect conditioning?