[R-meta] Sample sized weighted studies for metamean function
Dr. Guido Schwarzer
gu|do@@chw@rzer @end|ng |rom un|k||n|k-|re|burg@de
Thu Oct 17 12:25:59 CEST 2024
Massimo,
R package meta does not have an argument like 'weights' to provide user-defined weights.
You could use metamean() from R package meta to approximate the standard error from quantiles and use the calculated values as input to rma() from R package metafor. List elements 'TE', 'seTE', and 'n' from a metamean object contain the necessary input to rma().
Best,
Guido
P.S. I notice in your rma command the assignment 'vi = MVR_data$time_SD' which is probably wrong. Argument 'vi' expects a variance (you could use argument 'sei' to provide a standard error). Furthermore, time_SD doesn't sound like a standard error which you could provide in argument 'sei'. It is possible to provide the information for studies with single means using arguments 'mi', 'sdi' and 'ni'; see the help page of escalc().
-----Ursprüngliche Nachricht-----
Von: R-sig-meta-analysis <r-sig-meta-analysis-bounces using r-project.org <mailto:r-sig-meta-analysis-bounces using r-project.org>> im Auftrag von R-meta <r-sig-meta-analysis using r-project.org <mailto:r-sig-meta-analysis using r-project.org>>
Antworten an: R-meta <r-sig-meta-analysis using r-project.org <mailto:r-sig-meta-analysis using r-project.org>>
Datum: Mittwoch, 16. Oktober 2024 um 19:22
An: R-meta <r-sig-meta-analysis using r-project.org <mailto:r-sig-meta-analysis using r-project.org>>
Cc: Massimo Baudo <massimo.baudo using icloud.com <mailto:massimo.baudo using icloud.com>>
Betreff: [R-meta] Sample sized weighted studies for metamean function
Dear Community,
I have the following question regarding the metamean function in meta, and couldn’t find any previous threads on this regard.
I would like to calculate the pooled estimated mean of a follow-up time parameter: time from the first surgery to the second surgery. Studies report either mean (SD), or median (q1-q3). From my understanding (let me know if I am wrong), only the inverse of the variance is used to estimate the studies in metamean. This would be incorrect from my point of view to be used in this specific case, as the assumption is that larger studies have lower variance, thus weighted higher. However, for “follow-up” parameters larger studies could still have a large variance as some patients may have the whole follow-up length, while others would have a very short one. In this case, these larger studies would be weighted less (as if they were smaller studies), while smaller studies, which may have a smaller variance, would be weighted very high. Therefore, I would prefer to weight this parameter by the sample size. I could do it with metafor as follows:
MVR_data$weights = MVR_data$Samplesize / sum(MVR_data$Samplesize)
meta_analysis <- rma(yi = MVR_data$time_mean, vi = MVR_data$time_SD, weights = MVR_data$weights, data = MVR_data, method = “DL")
summary(meta_analysis)
This way though, I “loose” the very useful function of mean/SD approximation of the metamean function when dealing with median/q1/q3 or min/max.
Is there a possible solution to my problem with metamean?
Thank you for your support,
Massimo
[[alternative HTML version deleted]]
_______________________________________________
R-sig-meta-analysis mailing list @ R-sig-meta-analysis using r-project.org <mailto:R-sig-meta-analysis using r-project.org>
To manage your subscription to this mailing list, go to:
https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis <https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis>
More information about the R-sig-meta-analysis
mailing list