Learn R Programming

metaplus (version 1.0-5)

testOutliers: Tests for the presence of outliers.

Description

For the \(t\)-distribution models this is a test that the degrees of freedom is infinitite, or equivalently that it's inverse is zero. For the mixture-normal model it is a test that the proportion of outliers is zero. As both tests involve a parameter on the boundary of the parameter space, asymptotic theory does not apply, so a parametric bootstrap is performed to determine the empirical distribution of the test statistic under the null hypothesis. The observed likelihood ratio statistic is then compared to this distribution to determine the p value.

Usage

# S3 method for metaplus
testOutliers(object, R = 999, cores = max(detectCores()%/%2, 1))

Value

pvalue

p value obtained from parametric bootstrap

observed

Observed value of the likelihood ratio test statistic

sims

Simulated values of the test statistic under the null hypothesis

Arguments

object

The meta-analysis for which the presence of outliers is to be tested.

R

Number of simulations (parametric bootstraps) used in testing the hypothesis. Initially, it may be useful to set this to a smaller value, to allow faster execution time.

cores

Number of cores used to simultaneously perform simulations.

Author

Ken Beath <ken@kjbeath.id.au>

Examples

Run this code
# \donttest{
data(cdp)
cdp3 <- metaplus(yi, sei , plotci = TRUE, slab = study, random = "mixture", cores = 1, data = cdp)
summary(testOutliers(cdp3, cores = 1))
# }

Run the code above in your browser using DataLab