R package to fit linear and generalized linear mixed models with various extensions, including zero-inflation.
Questions tagged [glmmtmb]
138 questions
13
votes
1 answer
How are PQL, REML, ML, Laplace, Gauss-Hermite related to each other?
While learning about the Generalized Linear Mixed Models, I often see the above terms. Sometimes it seems to me these are separate methods of estimation of (fixed? random? both?) effects, but when I read the literature, I see the terms mixed. For…

humbleasker
- 257
- 2
- 8
8
votes
4 answers
Is it mandatory to subset your data to validate a model?
I'm having a hard time getting on the same page as my supervisor when it comes to validating my model. I have analyzed the residues (observed against the fitted values) and I used this as an argument to discuss the results obtained by my model,…

Eric Lino
- 203
- 1
- 7
7
votes
1 answer
Interpreting a zero-inflation negative binomial model
I am currently running a series of zero-inflated negative binomial models on the impact of the magnitude and direction of change in various weather parameters on a number of insect behaviours (represented as counts of the number of times the…

Ladybird_biologist
- 197
- 5
7
votes
0 answers
Understanding AR1 through the glmmTMB package
I've been working through a reproducible example to better understand AR1 covariance matrix using the glmmTMB package. I have a couple of questions, even if only one can be answered I would greatly appreciate it.
Here is some synthetic data, many…

Will T-E
- 429
- 1
- 6
- 14
6
votes
1 answer
Interpreting random effects in zero-inflated models
For context, I have a longitudinal study measuring counts of bacterial sequences in human stool collected during a dietary intervention.
Initially, I was going model the change in each bacterium (sequence) over time using a Negative Binomial…

Moose
- 1,090
- 7
- 12
6
votes
3 answers
Checking a beta regression model via glmmTMB with DHARMa package
I would like some clarification whether my model is well specified or not (since I do not have much experience with Beta regression models).
My variable is the percentual of dirth area in the denture. For every pacient, the dentist applied a special…

Guilherme Parreira
- 265
- 2
- 12
5
votes
1 answer
GLM modeling binomial proportions with varying trials and probabilities
A collection of coin manufacturers, $m$, each produces a line of coins, the number of which varies by manufacturer (some produce 3 types of coins, others make 7, and so on). Each manufacturer imparts a characteristic bias towards flipping heads on…

a crab
- 51
- 3
5
votes
2 answers
Overdispersion parameter in R's glmmTMB
I am using R's glmmTMB for modeling negative binomial mixed effects. In the output, I see the following line : Overdispersion parameter for nbinom2 family (): 9.28e+06.
How do I interpret such a large overdispersion? Please help.

SanMelkote
- 621
- 5
- 20
4
votes
0 answers
Accounting for repeated measures by resampling data and averaging parameter estimates misses the mark, but why?
Let's say I am looking at how unicorn herd size changes with food quantity. Unicorn herd sizes were surveyed at seven localities over the course of twelve months. Food quantity was assessed monthly, so for each locality at each month we have one…

Marco Plebani
- 779
- 4
- 17
4
votes
1 answer
Generalized Mixed Model with repeated measurements
I’ve have been working with a mixed model (glmmTMB) to analyse the abundance of snails in dependency of several categorical predictors. The data was measured twice in the same sample sites in two different years (YEAR) and at 11 different farms…

Sonja
- 41
- 1
4
votes
1 answer
Selecting between a zero-inflated binomial, OLRE and beta-binomial model
I need some help in deciding which of the following models fits best the data that I have.
This was a survey where participants reported proportions of successes (defined as n/m) in condition A and B. The model predicts the proportions by the binary…

User33268
- 1,408
- 2
- 10
- 21
4
votes
1 answer
crossed random effects with autoregression, glmmTMB
I am working on data that have crossed random effects as well as a autoregressive covariance structure. I would like to check if there is something unlogical about my approach, as the model I would like to fit produces problems in the Hessian. I am…

Peter
- 41
- 2
4
votes
0 answers
R: lme4 vs. glmmTMB for binomial GLMM
I am fitting a GLMM to test if parasite prevalence in snails (positive snails divided by total snails) differs between different sites (site_type). Sites were sampled repeatedly over several months, so month was included as a random effect.
I have…

Joris
- 269
- 3
- 9
4
votes
1 answer
assessing glmmTMB hurdle model fit using DHARMa scaled residual plot
My model
glmmTMB(y~fixed1+fixed2+fixed3+fixed4+(1|random),data=df,ziformula~.,
family=list(family="truncated_nbinom1",link="log"))
The response variable (y) is e.g. kilos of wheat seeds planted per month. This involves two decisions (1)…

user157607
- 41
- 3
4
votes
1 answer
Covariance structures in glmmTMB for temporal autocorrelation
I'm running a zero-inflated, mixed-effects negative binomial model with the glmmTMB package in R.
My current format:
mod1 = glmmTMB(count ~ a + b + offset(c) + (1|d) + (1|e), ziformula= ~a, data = dat, family = nbinom2(link = 'log'))
I have…

Andrew
- 41
- 3