Description Usage Arguments Details Value Note Author(s) References See Also Examples

These functions implement maximum likelihood (ML) and restricted maximum likelihood (REML) estimators for random-effects meta-analysis and meta-regression, including standard univariate models, and non-standard extensions such as multivariate, multilevel, longitudinal, and dose-response models. These functions are meant to be used internally and not directly run by the users.

1 2 3 | ```
mixmeta.ml(Xlist, Zlist, ylist, Slist, nalist, rep, k, q, nall, bscov, control, ...)
mixmeta.reml(Xlist, Zlist, ylist, Slist, nalist, rep, k, q, nall, bscov, control, ...)
``` |

Assuming a meta-analysis or meta-regression based on *n* units aggregated within *m* (outer-level) groups, *k* outcomes, *p* fixed-effects predictors, and *q* random-effects predictors:

`Xlist ` |
a |

`Zlist ` |
a |

`ylist ` |
a |

`Slist ` |
a |

`nalist ` |
a |

`rep ` |
matrix with |

`k, q, nall ` |
number of outcomes, number of random-effects predictors (including the intercept), total number of observations (excluding missing), respectively. While usually all are scalars, in the case of multilevel models |

`bscov ` |
a character vector defining the structure of the (co)variance matrix for each level or random effects. See |

`control ` |
list of parameters for controlling the fitting process, usually internally set to default values by |

`... ` |
further arguments passed to or from other methods. Currently not used. |

The estimation involves *kp* fixed-effects coefficients and random-effects parameters, whose number depends on the number of grouping levels and, for each of them, on the chosen `(co)variance structure`

for the between-study (co)variance matrices. A maximum of *kq(kq+1)/2* parameters are needed in the case of or single-level models with unstructured form for the random-effects (co)variance matrix.

(Restricted) maximum likelihood estimators implemented in mixmeta rely on two iterative algorithms: `(R)IGLS`

and `quasi-Newton`

iterative methods. The former implements a (restricted) iterative generalized least squares method, while the latter is based on a Newton-type maximization routine using specific `likelihood functions`

. The default estimation method is based on a hybrid procedure, with few runs of of the (R)IGLS algorithm and then quasi-Newton iterations until convergence. This approach is optimal in exploiting the properties of both algorithms, with (R)IGLS being robust to the choice of initial values and quick in getting near the maximum, while the quasi-Newton is fast to converge from that point. Full (R)IGLS or quasi-Newton methods can be alternatively selected using the `control`

argument of `mixmeta`

(see `mixmeta.control`

). Follow the links above for details on each iterative algorithm.

Both estimation algorithms adopt a profiled (or concentrated) approach, where the optimization is expressed only in terms of the random-effects parameters. Cholesky and and QR decompositions are used for computational stability and efficiency, and for assuring the positive-definiteness of the estimated between-study (co)variance matrix. The method is described in details in Gasparrini and collaborators (2012) (see references below).

These functions return an intermediate list object, with some components then processed and some others added later within `mixmeta.fit`

and `mixmeta`

to finalize an object of class `"mixmeta"`

. See `mixmetaObject`

.

As stated earlier, these functions are called internally by `mixmeta.fit`

, and are not meant to be used directly. In particular, their code does not contain any check on the arguments provided, which are expected in specific formats. The functions are not exported in the namespace, and only documented for completeness.

The arguments above are prepared by `mixmeta.fit`

from its arguments `X`

, `Z`

, `y`

, `S`

, `groups`

, and `bscov`

. The list structure, although requiring more elaborate coding, is computationally more efficient, as it avoids the specification of sparse block-diagonal matrices, especially for meta-analysis involving a large number of studies.

Some parameters of the fitting procedures are determined by the `control`

argument, with default set by `mixmeta.control`

. No missing values are accepted in the fitting functions. See details on `missing values`

.

Antonio Gasparrini <antonio.gasparrini@lshtm.ac.uk> and Francesco Sera <francesco.sera@lshtm.ac.uk>

Sera F, Armstrong B, Blangiardo M, Gasparrini A (2019). An extended mixed-effects framework for meta-analysis.*Statistics in Medicine*. 2019;38(29):5429-5444. [Freely available **here**].

Gasparrini A, Armstrong B, Kenward MG (2012). Multivariate meta-analysis for non-linear and other multi-parameter associations. *Statistics in Medicine*. **31**(29):3821–3839. [Freely available **here**].

Pinheiro JC and Bates DM (2000). *Mixed-Effects Models in S and S-PLUS*. New York, Springer Verlag.

Lindstrom MJ and Bates DM (1988). Newton-Raphson and EM algorithms for linear mixed-effects models for repeated-measures data. *Journal of the American Statistical Association*. **83**(404):1014–1022.

Goldstein H (1986). Multilevel mixed linear model analysis using iterative generalized least squares. *Biometrika*. **73**(1):43.

Goldstein H (1992). Efficient computational procedures for the estimation of parameters in multilevel models based on iterative generalized least squares. *Computational Statistics \& Data Analysis*. **13**(1):63–71.

See `mixmeta`

for the general usage of the functions. See `mixmeta.control`

to determine specific parameters of the fitting procedures. Use the triple colon operator ('`:::`

') to access the code of the internal functions, such as `glsfit`

. See `mixmeta-package`

for an overview of the package and modelling framework.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ```
# REML ESTIMATOR: UNIVARIATE MODEL
mod1 <- mixmeta(yC, S=SCC, data=smoking)
summary(mod1)
# ML ESTIMATOR: MULTIVARIATE MODEL
year <- berkey98$pubyear - 1983
mod2 <- mixmeta(cbind(PD,AL) ~ year, S=berkey98[5:7], data=berkey98,method="ml")
print(summary(mod2), digits=3)
round(mod2$Psi,3)
# STRUCTURED BETWEEN-STUDY (CO)VARIANCE
y <- as.matrix(fibrinogen[2:5])
S <- as.matrix(fibrinogen[6:15])
mod3 <- mixmeta(y, S, bscov="hcs")
summary(mod3)
# MULTILEVEL MODEL
mod4 <- mixmeta(effect, var, random= ~ 1|district/study, data=school)
summary(mod4)
# LONGITUDINAL MODEL
mod5 <- mixmeta(logOR~time, S=logORvar, random=~I(time-15)|study, bscov="diag",
method="ml", data=gliomas)
summary(mod5)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.