# Data set -- see Introduction to the New Statistics, 2nd edition
data("data_mccabemichael_brain")
# Fixed effect, 95% CI
estimate <- esci::meta_mean(
data = esci::data_mccabemichael_brain,
means = "M Brain",
sds = "s Brain",
ns = "n Brain",
labels = "Study name",
random_effects = FALSE
)
myplot_forest <- esci::plot_meta(estimate)
# Add a moderator, report cohen's d1
estimate_moderator_d <- esci::meta_mean(
data = esci::data_mccabemichael_brain,
means = "M Brain",
sds = "s Brain",
ns = "n Brain",
labels = "Study name",
moderator = "Research group",
reported_effect_size = "smd_unbiased",
random_effects = FALSE
)
# Forest plot
myplot_forest_moderator_d <- esci::plot_meta(estimate_moderator_d)
Run the code above in your browser using DataLab