Description Usage Arguments Details Value Author(s) References See Also Examples
This internal function computes mean and standardized mean of a continuous outcome with the corresponding variances. It also reconstructs the covariance matrix from the available data.
1 |
y |
a vector defining the mean outcome for each treatment level. |
sd |
a vector defining the standard deviation of the outcome for each treatment level. |
n |
a vector defining the number of subjects for each treatment level. |
measure |
character string, indicating the measure to be calculated. Options are |
method |
character string indicating the method to be used. Options are |
data |
an optional data frame (or object coercible by |
This is an internal function called by dosresmeta
to reconstruct the (co)variance matrix of the
outcome variable. The function is expected to be extended and/or modified at every release of the package
A list containing the following
y | mean or standardized mean differences for each treatment level, included the referent one (0 by calculation). |
v | variances corresponding to the mean or standardized mean differences for each treatment level, included the referent one (0 by calculation) |
S | co(variance) matrix for the non-referent mean or standardized mean differences. |
Alessio Crippa, alessio.crippa@ki.se
Cooper, H., Hedges, L. V., & Valentine, J. C. (Eds.). (2009). The handbook of research synthesis and meta-analysis. Russell Sage Foundation.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Loading the data
data("ari")
## Obtaining standardized mean differences, variances, and (co)varinace
## matrix for the first study (id = 1)
covar.smd(y, sd, n, measure = "smd", data = subset(ari, id == 1))
## Obtaining mean differences, variances, and (co)varinace matrices for the all the studies
cov.md <- by(ari, ari$id, function(x) covar.smd(y, sd, n, "md", data = x))
## Extracting mean differences
unlist(lapply(cov.md, function(x) x$y))
## Extracting variances for the mean differences
unlist(lapply(cov.md, function(x) x$v))
## List of the (co)variance matrices for the mean differences
lapply(cov.md, function(x) x$S)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.