ranef {ptmixed}R Documentation

Compute random effects for Poisson-Tweedie and negative binomial mixed model

Description

Compute the BLUP (best linear unbiased predictor) of the random effects for the Poisson-Tweedie and negative binomial generalized linear mixed models (fitted through ptmixed and nbmixed respectively)

Usage

ranef(obj)

Arguments

obj

an object of class ptglmm (obtained from ptmixed or nbmixed ).

Value

A vector with the EB estimates of the random effects

Author(s)

Mirko Signorelli

References

Signorelli, M., Spitali, P., Tsonaka, R. (2021). Poisson-Tweedie mixed-effects model: a flexible approach for the analysis of longitudinal RNA-seq data. Statistical Modelling, 21 (6), 520-545. URL: https://doi.org/10.1177/1471082X20936017

See Also

ptmixed, nbmixed

Examples



data(df1, package = 'ptmixed')

# estimate a Poisson-Tweedie or negative binomial GLMM (using
# ptmixed() or nbmixed())
fit0 = nbmixed(fixef.formula = y ~ group + time, id = id,
              offset = offset, data = df1, npoints = 5, 
              freq.updates = 200, hessian = FALSE, trace = TRUE)
              
# obtain random effect estimates
ranef(obj = fit0)


[Package ptmixed version 1.1.3 Index]