This function estimates the intercept and slope coefficients in a meta-regression model where the dependent variable is a G-index of agreement. The estimates are OLS estimates with robust standard errors that accomodate residual heteroscedasticity.
meta.lm.agree(alpha, f11, f12, f21, f22, X)
alpha level for 1-alpha confidence
vector of frequency counts in cell 1,1
vector of frequency counts in cell 1,2
vector of frequency counts in cell 2,1
vector of frequency counts in cell 2,2
matrix of predictor values
Returns a matrix. The first row is for the intercept with one additional row per predictor. The matrix has the following columns:
Estimate - OLS estimate
SE - standard error
z - z-value
p - p-value
LL - lower limit of the confidence interval
UL - upper limit of the confidence interval
f11 <- c(40, 20, 25, 30)
f12 <- c(3, 2, 2, 1)
f21 <- c(7, 6, 8, 6)
f22 <- c(26, 25, 13, 25)
x1 <- c(1, 1, 4, 6)
x2 <- c(1, 1, 0, 0)
X <- matrix(cbind(x1, x2), 4, 2)
meta.lm.agree(.05, f11, f12, f21, f22, X)
#> Estimate SE z p LL UL
#> b0 0.1904762 0.38772858 0.4912617 0.623 -0.56945786 0.9504102
#> b1 0.0952381 0.07141957 1.3335013 0.182 -0.04474169 0.2352179
#> b2 0.4205147 0.32383556 1.2985438 0.194 -0.21419136 1.0552207
# Should return:
# Estimate SE z p LL UL
# b0 0.1904762 0.38772858 0.4912617 0.623 -0.56945786 0.9504102
# b1 0.0952381 0.07141957 1.3335013 0.182 -0.04474169 0.2352179
# b2 0.4205147 0.32383556 1.2985438 0.194 -0.21419136 1.0552207