I am currently performing supbgroup anlyses on a published review. I am doing analyses on heterogeneity, and would like to get the confidence intervals for tau2 and have them printed in my forest plot.
I can't seem, to find the code for adding this, and was wondering if it exists?
This is my code - unfortunately, it does not seem like I can attach my excel file from which the data is drawn. As such the error messages generated by reprex are not relevant if you have the file loaded.
library(meta)
#> Indlæser krævet pakke: metadat
#> Loading 'meta' package (version 7.0-0).
#> Type 'help(meta)' for a brief overview.
#> Readers of 'Meta-Analysis with R (Use R!)' should install
#> older version of 'meta' package: https://tinyurl.com/dt4y5drs
x.sub<-metacont(data = ADHD_symptom_severity,
TotalMph, MeanMph, SDMph, TotalControl, MeanControl, SDControl,
method.smd = "H",method.tau = "DL",sm="SMD",
studlab=StudyID,
prediction=TRUE,
random=TRUE, common=FALSE,
subgroup = ADHD_symptom_severity$`Study design`,
subgroup.name = "Study design",
prediction.subgroup=TRUE)
#> Error in eval(expr, envir, enclos): objekt 'ADHD_symptom_severity' blev ikke fundet
summary(x.sub)
#> Error in eval(expr, envir, enclos): objekt 'x.sub' blev ikke fundet
pdf("ADHDsymptoms.StudyDesignnew6.pdf", height=40, width = 20)
forest(x.sub,
leftlabs = "Favours Mph", rightlabs = "Favours Control",
col.subgroup = "black",
col.study = "grey",
col.square = "black",
col.square.lines = "grey",
print.I2.ci = TRUE, print.tau2.ci = TRUE, print.Q = TRUE,
prediction=TRUE,
random = TRUE,
xlim=c(-3.5,1.25),
plotwidth = "10cm",
prediction.subgroup = TRUE,
layout="RevMan5")
#> Error in eval(expr, envir, enclos): objekt 'x.sub' blev ikke fundet
dev.off()
#> png
#> 2
reprex()
#> Error in reprex(): could not find function "reprex"
Created on 2024-07-26 with reprex v2.1.1