Type: | Package |
Title: | Fit and Test Metaregression Models |
Version: | 1.0-5 |
Date: | 2018-12-06 |
Author: | Hilde M. Huizenga & Ingmar Visser |
Maintainer: | Ingmar Visser <i.visser@uva.nl> |
Description: | Fits and tests meta regression models and generates a number of useful test statistics: next to t- and z-tests, the likelihood ratio, bartlett corrected likelihood ratio and permutation tests are performed on the model coefficients. |
Depends: | R (≥ 3.5.0) |
License: | GPL-2 | GPL-3 [expanded from: GPL] |
LazyLoad: | yes |
NeedsCompilation: | no |
Packaged: | 2018-12-06 09:18:40 UTC; ingmar |
Repository: | CRAN |
Date/Publication: | 2018-12-06 22:10:19 UTC |
metatest fits and tests a metaregression model
Description
metatest
fits and tests a metaregression model. In addition to
the traditional z test on the estimated coefficients, metatest
also yields more reliable statistics: the t-test, log likelihood ratio
test, Bartlett corrected log likelihood ratio test, and the permutation
test. The Bartlett corrected log likelihood ratio test and the
permutation test are to be recommended since their type 1 errors are
adequate.
See metatest
for details and an example.
Details
Package: | metatest |
Type: | Package |
Version: | 1.0-2 |
Date: | 2011-10-04 |
License: | GPL |
LazyLoad: | yes |
Author(s)
The code that does the hard work was written by Hilde Huizenga. Ingmar Visser added the interface functions and handled turning code into a package. Maintainer: Ingmar Visser <i.visser@uva.nl>
References
Hilde M. Huizenga, Ingmar Visser & Conor V. Dolan (2011). Hypothesis testing in random effects meta-regression, British Journal of Mathematical and Statistical Psychology, 64, 1-19.
Example data for meta regression testing.
Description
Small example data set used in the example on the metatest help page.
Usage
data(metadata)
Format
A data frame with 6 observations on the following 3 variables.
y
The effect sizes.
yvar
The variances of the effect sizes.
x
A moderator variable.
Source
Data were randomly generated following an example in Huizenga et al (2011) below.
References
Hilde M. Huizenga, Ingmar Visser & Conor V. Dolan (2011). Hypothesis testing in random effects meta-regression, British Journal of Mathematical and Statistical Psychology, 64, 1-19.
Examples
data(metadata)
metadata
metatest fits and tests a metaregression model
Description
metatest
fits and tests a metaregression model. In addition to
the traditional z test on the estimated coefficients, metatest
also yields more reliable statistics: the t-test, log likelihood ratio
test, Bartlett corrected log likelihood ratio test, and the permutation
test. The Bartlett corrected log likelihood ratio test and the
permutation test are to be recommended since their type 1 errors are
adequate.
Usage
metatest(formula, variance, data, threshold = 1e-05, maxiter = 100, npermut = 1000, ...)
## S3 method for class 'metatest'
summary(object, digits = 4, ...)
## S3 method for class 'metatest'
print(x, ...)
Arguments
formula |
|
variance |
The variances of the effect sizes to be modelled (a
vector or a variable name interpreted in |
data |
A |
threshold |
The threshold used in estimating the model; the threshold is the change in the value of the random effects variance parameter. |
maxiter |
Maximum number of iterations allowed in estimating the model. |
npermut |
Number of permutations performed by the permutation test. |
object , x |
Object of class |
digits |
Determines the number of digits to use in printing the results. |
... |
Not currently used. |
Details
The effect sizes to be analyzed can be of arbitrary type; some
transformations
between different effect size measures
are provided. For many more see the package compute.es.
The print and summary methods are currently identical (this may change in the future), and print the random effects variance, the coefficients, and all the computed statistics and associated p-values.
Value
metatest
returns an object of class metatest
which is a named list
with the following elements:
convergence |
Convergence info; 0 indicates convergence; -1 signals that the estimator of between study variance was set to zero during estimation (with a warning). |
iter |
Number of iterations used in optimizing the parameters. |
variance |
Matrix with between study variance estimate, its associated log likelihood ratio statistic, df and p-value. |
coefficients |
Estimated coefficients. |
se |
Standard errors of the coefficients. |
tval |
The t-ratios of the coefficients. |
pZtest |
The p-values associated with the z-test. |
dfttest |
The df's associated with the t-tests. |
pttest |
The p-values associated with the t-test. |
LLR |
The log likelihood ratio statistics. |
pLLR |
The p-values associated with the LLR statistics. |
bartLLR |
The Bartlett corrected LLR statistics. |
bartscale |
The Bartlett scaling factor used to compute the corrected LLR statistics. |
pBartlett |
The p-values associated with the Bartlett corrected LLR statistics. |
ppermtest |
The p-values of the permutation tests. |
call |
The function call that created the metatest object. |
Author(s)
Ingmar Visser & Hilde Huizenga. Maintainer: Ingmar Visser <i.visser@uva.nl>
References
Hilde M. Huizenga, Ingmar Visser & Conor V. Dolan (2011). Hypothesis testing in random effects meta-regression, British Journal of Mathematical and Statistical Psychology, 64, 1-19.
Examples
data(metadata)
res <- metatest(y~x,yvar,data=metadata)
res
metatest internal functions
Description
Internal functions for metatest.
Details
These are not to be called by the user.
Author(s)
Hilde Huizenga
Transform effect sizes.
Description
Utility functions to transform various effect size measures into each other.
Usage
r2z(r)
r2d(r)
z2r(z)
z2d(z)
Arguments
r |
A correlation coefficient. |
z |
A z-value, ie a normalized effect size. |
Details
Transform effect sizes into correlations, (Cohen's) d effect sizes, or z-distributed for performing meta regression.
Value
Return values are z, d or r values.
Author(s)
Ingmar Visser.
References
Tba
Examples
## The function r2z is currently defined as
function(r) {
return(0.5*(log(1+r)-log(1-r)))
}