Quantile residuals for a Tweedie GLMM fit with glmmTMB

qres_tweedie(obj, response)

qres_binomial(obj, response)

qres_gamma(obj, response)

qres_gaussian(obj, response)

plot_qres_qq(qr, nmax = 10000)

plot_qres_histogram(qr, bins = 50, nmax = 10000)

Arguments

obj

A model object from glmmTMB::glmmTMB().

response

The name of the response column in the data. E.g. "cpue".

qr

A vector of quantile residuals from qres_tweedie().

nmax

The maximum number of residuals to plot. Very large values will take a while to plot.

bins

The number of histogram bins.

Examples

m <- glmmTMB::glmmTMB(cpue ~ 1, data = data.frame(cpue = tweedie::rtweedie(1000, mu = 2, phi = 5, power = 1.5)), family = glmmTMB::tweedie(link = "log")) qr <- qres_tweedie(m, "cpue") plot_qres_qq(qr)
plot_qres_histogram(qr)