Posterior modes and posterior standard deviations of the unit random intercept(s), from the adaptive quadrature at the fitted parameters.
Value
A data frame with one row per unit: unit, u (outcome-equation
intercept), u_sd, and for re_inflation = TRUE also v, v_sd.
See also
The re, re_inflation, and nAGQ arguments of oprobit() and
iop(); predict.iord() for marginal and conditional probabilities.
Other panel tools:
mundlak()
Examples
set.seed(3)
d <- riop(300, beta = c(0.8, -0.5), tau = c(-0.5, 0.7))
d$unit <- rep(1:15, each = 20)
m <- oprobit(y ~ x1 + x2, d, re = "unit", nAGQ = 7)
#> Warning: oprobit: a random-intercept standard deviation is at zero: the data show no unit-level heterogeneity in that equation.
head(ranef(m))
#> unit u u_sd
#> 1 1 -2.339409e-11 3.1621e-06
#> 2 2 1.595808e-11 3.1621e-06
#> 3 3 2.199489e-11 3.1621e-06
#> 4 4 5.633959e-11 3.1621e-06
#> 5 5 -1.857501e-11 3.1621e-06
#> 6 6 -2.565354e-11 3.1621e-06
## marginal (population-averaged) vs conditional (u = 0) probabilities
head(cbind(predict(m)[, 1], predict(m, type = "prob_conditional")[, 1]), 3)
#> [,1] [,2]
#> [1,] 0.3397051 0.3397051
#> [2,] 0.5192576 0.5192576
#> [3,] 0.1306866 0.1306866