Questions tagged [glmmtmb]

R package to fit linear and generalized linear mixed models with various extensions, including zero-inflation.

Filter by
Sorted by
Tagged with
1
vote
1answer
27 views

Model residual diagnostics of gamma GLMM with log-link

I am trying to model fish length data (N > 115.000) which are highly right-skewed using linear mixed effects models. Actually all data make sense and the the extreme high values are valid ...
0
votes
0answers
43 views

MMRM(Mixed Model for Repeated Measures) in glmmTMB using R

I am currently trying to analyze data using a model called MMRM (Mixed Model for Repeated Measures).I think it was first proposed in this document. Mallinckrodt, C. H., Clark, W. S., & David, S. R....
0
votes
0answers
7 views

Shifting Raw Count Data for Covariate Effects in glmmTMB

I am looking for help on adjusting the values of my raw data (dependent variable = Count) based on the effects of two continuous covariates to go alongside model-predicted estimates in a plot derived ...
1
vote
1answer
73 views

DHARMa testZeroInflation: how to interpret output?

I'm analyzing count data with a negative binomial GLMM via the R package glmmTMB and lme4. I'm running DHARMa diagnostics, one of which is testing for zero inflation and I'm having some trouble ...
1
vote
0answers
17 views

GLM in R: How to set the dependent variable as a number of events (rows in dataset)?

I am carrying out GLMMs with glmmTMB, and my dataset contains rows of video analyses (behaviour analyses of recorded videos of deer) and columns of different data (camera id, date, time, behavioural ...
1
vote
1answer
96 views

Interpretation of Positive Count Coefficients in Hurdle Model

What is the proper interpretation of the coefficients for the positive count part of a hurdle model (truncated Poisson or Negative Binomial)? I have read that the interpretation of the coefficients ...
1
vote
0answers
14 views

Is Hurdle model recommended if there is a few zero counts?

Is Hurdle model recommended if there is small number of zero counts? Is there any limit for the zero count to fit Hurdle model?
2
votes
1answer
104 views

How to implement a mixed-model with a beta distribution?

I am interested in using a generalised linear mixed model with a response variable (values ranging from 0.001-0.999) that best fits a beta distribution when checked using the 'fitdistrplus' package ...
0
votes
0answers
12 views

post-hoc tests for a GLMM with polynomial term

I have count data (winter bud production) from a greenhouse experiment in which 48 plant genotypes were subjected to 4 salinity treatments ranging from low to high salinity. For optimal model fitting ...
2
votes
0answers
96 views

How to correct spatial autocorrelation with glmmTMB when there are several observations on sites?

I have a large dataset of several species' activity parameters during nights and I want to account for spatial autocorrelation (tests and graphs show that my models suffer from it). However, I cannot ...
5
votes
1answer
107 views

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 ...
3
votes
1answer
48 views

Grouping Factor throws model off

One grouping factor of my model appears to pose a problem for model fit. Let me elaborate: I tried to fit a GLMM to ecological data for a behavioural study on termites. I did 80 experiments split ...
0
votes
0answers
31 views

Is a (beta)binomial model fitting for my response variable?

I am working on the evaluation of a speech recognition system we trained. The recognizer basically is given a query utterance containing a single word and should find images containing the appropriate ...
3
votes
0answers
59 views

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, ...
2
votes
1answer
306 views

Convergence issues and model selection in glmmTMB

Convergence problems in mixed effect models seem to be a common struggle. It is my understanding that they emerge when the likelihood surface is too flat for the optimisation algorithms to find a ...
0
votes
0answers
96 views

Problems with uniformity in residuals using DHARMA to check zero-inflated count glmm

very new to statistical modelling & have found lots of the existing questions and answers from this community hugely helpful. I'm running into some issues of my own now that I can't find answers ...
0
votes
1answer
72 views

Temporal autoregression in glmmTMB: what do alternative syntax forms mean?

The argument ar1() in glmmTMB accepts two different forms of syntax (that I know of, there might be others): ...
0
votes
0answers
61 views

Does pairwise correlation and multicollinearity matter in dispersion and zeroinflation model of glmmTMB?

I'm using glmmTMB to calculate beta-binomial GLMMs with nested and crossed random intercepts. I have overdispersed, zero-inflated data (assessed with Dharma). I use continuous terms in the very ...
1
vote
0answers
263 views

Varying dispersion parameter (=dispformula) in glmmTMB in R to account for heteroscedasticity that originates from one predictor

I struggle with understanding the dispersion model and dispersion parameter of glmmTMB , and could not find answers anywhere. I constructed a GLMM using ...
0
votes
0answers
26 views

Infinite upper and lower CL after fitting the model (glmmtmb)

I am new in GLMM. In my dataset, There are 2 islands, 2 sites were selected (nonrandom) per each island, 6 transects randomly were located on each site, then the number of corals was counted in three ...
4
votes
1answer
63 views

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 ...
0
votes
0answers
60 views

Validation, Interpretation and Post-hoc testing with a zero-truncated GLMM (using glmmTMB, DHARMa and emmeans)

I tried to go as far on my own as I could. But after 6 months of searching and reading, I'm still unsure if everything I did is statistically sound. Unfortunately, I neither have a statistican nor ...
0
votes
0answers
16 views

building a good (mixed) linear model for agri-ecology data [duplicate]

I encountered an problem. I cannot build a good mixed linear model. For example, ...
0
votes
0answers
75 views

Can glmmTMB be used without a random effect?

I'm curious whether glmmTMB can be used without a random effect. Both glmer, lmer, and ...
0
votes
0answers
60 views

How to handle exces zero's in a continuous (multilevel) outcome: two-part model or Tweedie distribution?

I am trying to fit a hierarchical model on a continuous outcome that has excess zero's. This is what my data looks like: The formula for both the main part as well a possible zero-part of the model ...
1
vote
0answers
47 views

Including dispersion parameter in prediction

I have already posted this question on r-sig-mixed-models mailing list but I received no response. I am fitting a ziGamma model using glmmTMB to predict the ...
0
votes
0answers
26 views

R: repeated subsampling for unbalanced design with zero-inflated count data using glmmtmb

I have count data with the number of individuals per observation of 64 different plant species. 3 - 5 observations were made of each plant species, and the number of arthropods on the plants were ...
0
votes
0answers
31 views

What is the most appropriate regression model to use to predict an outcome variable which is continuous but bound between 0 and 1?

I have a panel dataset of patients visiting the hospital multiple times and their health index (measured by variables SFPCS and SFMCS) is measured at each visit. Each patient may have different visit ...
0
votes
1answer
77 views

When to use Kenward-Roger, not standard glmmTMB

Please consider the following: ...
0
votes
0answers
27 views

How to evaluate overfitting in GLMMs usnig R

I am using glmmTMB in r to model count data. I use poison and negative binomial error distributions. If I add one more predictor to my models I end up having convergence problems. I would like to ...
0
votes
0answers
25 views

Do multiple model-fitting tests qualify as multiple comparisons?

My question: do I need to be concerned with multiple comparisons when fitting models to different (but related) sets of count data? My question expanded: I have a series of plots where we collected ...
0
votes
0answers
57 views

Handling 0s in a generalized linear model---climate data

I am using a generalized linear mixed model for analyzing climate data and incidence of a disease variable. The data follows a gamma distribution. But I am getting the following error when I am ...
0
votes
0answers
37 views

Which type to specify in ggpredict for GLMM with zero inflation and dispersion factor

Just wondering if I am using ggpredict to predict values for my response variable using the example model below, should I be using type="fe" or type="fe.zi"? And would this be the ...
0
votes
2answers
71 views

glmmTMB: random intercepts vs. spatial random field

I'm working on a modified example from a glmmTMB vignette (found here) using spatial covariance structures. I'm trying to show the difference between "standard&...
0
votes
0answers
98 views

Interpret the output of a Tweedie GLMM

I've fit the following glmm using the glmmTMB package with the tweedie(link = "log") distribution, where ...
0
votes
0answers
26 views

What would be a good next step in this GLMM analysis?

So I've got some count data over time looking at different treatment groups: My goal with this data is significance testing. I would like to show which treatments are effective in reducing counts, ...
0
votes
0answers
18 views

How to write up the results of a zero-inflation poisson model?

I am currently running a series of zero-inflation poisson mixed effects models using the glmmTMB function of the package of the same name and was curious about how you would write up the results of ...
0
votes
0answers
30 views

How to interpret the interaction of a zero-inflation model (logistic regression)

I have run a zero-inflation negative binomial mixed effects model looking at the effect of the amount of and direction of change in a particular environmental parameter (e.g. temperature) on the no of ...
1
vote
0answers
204 views

How to report and quantify the random effect in a logistic model? glmmTMB

I'm fitting a logistic regression model with mixed effects using the package glmmTMB. (Because the dataset is very large and lme4 produces out of memory errors). And I need help to interpret and ...
1
vote
0answers
181 views

Error in glmmTMB when fitting mixed model with interactions between two categorical variables

my mixed models contain several categorical variables with a lot of unique levels, so model matrix for fixed effects is ​​very sparse. I use glmmTMB package that ...
0
votes
0answers
51 views

random effect with one observation per group improves AIC drastically -- explain

Now that I've posted an example (for a different purpose) at How will random effects with only 1 observation affect a generalized linear mixed model? (resulting in creating an account here, and being ...
4
votes
1answer
205 views

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. ...
2
votes
0answers
213 views

How should I deal with spatial autocorrelation in beta GLMM (glmmTMB)? (Bird diversity)

I am trying to compare certain a taxonomic diversity index (for bird communities) calculated for squares in a map grid system (a total of 34 squares) for two different years: 1998 and 2018. My ...
2
votes
0answers
43 views

Why does uncorrelated random slope and intercept not convergence, but correlated random slope and intercept does converge?

In contrast to what I expected, I am able to fit a model with a correlated random intercept and slope, but not the same model with an uncorrelated random intercept and slope term. I was under the ...
0
votes
1answer
286 views

Significant dispersion test

I used DHARMa for my residual diagnostics. For two models, the dispersion test is significant even though the rest of the diagnostic output looks good. I am wondering if both my models are correct ...
1
vote
1answer
406 views

How does emmeans calculate degrees of freedom for glmmTMB?

I have a model that I'd really love to use glmmTMB for (beta distribution, mixed model, heterogeneous variance that the dispersion equation can help with). I found ...
2
votes
1answer
206 views

GLMM for unbalanced design, nested random factor or fixed factor?

The Goal Determine if the abundance of ectos differ between sites. The set up The data is percent abundance of ectomycorrhizal fungi from soil samples. There are ten soil samples per plot and there ...
0
votes
1answer
136 views

Plot correlation between random intercept and slope glmmTMB?

I am after some advice regarding how to plot the correlation between a random intercept and slope from a mixed model in glmmTBM? Below is a reproducible example. <...
0
votes
1answer
129 views

P value adjustment for pairwise comparisons of negative binomial

Question 1) Am I appropriately doing the pairwise comparisons? Question 2) Why is the Sidak method used for the emmeans? Should I instead use adjust = "none" for these? Context: I have a ...
1
vote
1answer
516 views

Mixed model with random slope but no random intercept?

I have two questions: Is it ok/when might it be ok to specify a mixed model with a random slope but no random intercept? How would one specify such a model in lme4/glmmTMB? I am working on a dateset ...