Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [glmmtmb]

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

1
vote
1answer
30 views

How to interprete the p values of cos and sin terms in periodic regression?

I have camera trap data where for each site and hour I have the abundance of wild herbivores. I want to create a model where I can estimate the effect of predator activity on the activity and behavior ...
1
vote
0answers
23 views

Why is the Degrees of Freedom 1 higher when model run with Poisson than Negative Binomial

Because the Negative Binomial distribution would result in there be an extra parameter to estimate the over dispersion, I am confused as to why I am getting a DF of 94 when I run the model with ...
0
votes
0answers
16 views

Overdispersion tests from DHARMa and sjstats: conflicting results?

I ran some models for my count data, and did some diagnostics to check for overdispersion. Here is a dharma graph, which as I understand, indicates no overdispersion. And this is the result I get ...
0
votes
0answers
31 views

Evaluating model fit for glmmTMB with beta distribution

I am looking for a way to evaluate model fit (e.g. R2, %deviance explained) for the following model: m1<-glmmTMB(AUC_indep~woody+dispersal+log_densitys+log_seedwts+I(log_seedwts^2)+(1|modeltype), ...
0
votes
1answer
46 views

DHARMa diagnostics: testDispersion and testZeroInflation interpretation

I have been analyzing count data using Poisson distribution in glmmTMB, and just ran some DHARMA diagnostics. However, there don't seem to be a lot of help online on how to interpret the results. Does ...
0
votes
0answers
46 views

Error: matrix-valued responses are not allowed in glmmTMB

I have some problems fitting a glmmTMB on my data. I am conducting a large synthesis analysis in an agricultural context including distance within the field and adjacent habitats. The model structure ...
1
vote
0answers
68 views

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

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 (<...
1
vote
1answer
159 views

Error when using vif() on glmmTMB obejct

I have run a zero-inflated model as follows: number of birds ~ treatment * date + minutes after sunrise + snow cover + (1|site) This was the code: ...
1
vote
1answer
138 views

R: GLMM for unbalanced zero-inflated data (glmmTMB)

Study design: I have count data of snails per date, counted over many dates at sites, nested in localities. So, in each locality the snail counts come from several different sites, repeatedly ...
0
votes
1answer
28 views

Longitudinal study - generalised linear mixed model - dealing with very wide confidence intervals due to sparsity in the outcome

I am conducting a treatment evaluation using administrative data. It is a population-based study of all people diagnosed with a specific disorder in two calendar years (N = 2300). I have run a GLMM ...
1
vote
1answer
53 views

Residuals still zero inflated after running zero-inflated poisson mixed effect model with glmmTMB

I am working with observational data which has a right skew in the dependent variable. This is a mixed effect model with a poisson distribution as based on discrete data. After finding the residuals ...
2
votes
0answers
123 views

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: ...
2
votes
1answer
212 views

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 : ...
1
vote
1answer
72 views

Zero-inflation GLMMs: On the use of different sets of explanatory variables in main and ZI formulas

my questions are general in nature so I won't provide any data. For reference: I am using the package glmmTMB in R so if my terminology is weird it is because it is a mix of this and other sources I'...
1
vote
0answers
252 views

Model convergence problem; non-positive-definite Hessian matrix with glmmTMB in R

I'm trying to fit a GLMM using the package glmmTMB in R. The model has a negative binomial distribution. The fixed effect "Treatment" has two levels (low or high), "Sampling" is the number of ...
1
vote
0answers
289 views

Seeking a post-hoc test for zero-inflated glmmTMB [closed]

I am attempting to use glmmTMB modelling zero-inflated count data following the example in Mollie Brooks' and Ben Bolker's paper: https://www.biorxiv.org/content/biorxiv/suppl/2017/05/01/132753.DC1/...
8
votes
4answers
242 views

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

Simulating by hand the predictions of a complex mixed model with beta distribution from glmmTMB for diagnostic

I am conducting a GLMM for a meta-analysis using the beta distribution with the package glmmTMB. My response variable is a vector of correlations (No exact 0 or 1), but Fisher’s transformation fails ...
0
votes
0answers
422 views

R-squared for glmmTMB with beta distribution and logit link

I'm looking for a method or function for computing R² for glmmTMB models with a beta distribution and a logit link. I am interested in a ratio (%) response in a repeated measures design. I looked ...
4
votes
1answer
606 views

Can you use glmmTMB to simultaneously model offsets and zero-inflation?

I'm currently modelling microbial data, with multiple samples and groups of samples. Two problems arise with my data: 1) The data is zero-inflated and dispersed (large variation); 2) Each sample has a ...
1
vote
0answers
305 views

How to adjust p-values and do post-hoc tests in glmmTMB models

I am running a glmmTBM model with repeated measures from a group of participants with 5 factors, one covariate and I have interaction between factors. I would like to ask what would be the best way ...
0
votes
0answers
189 views

Fitting GLMM to roe deer count data with glmmTMB: workflow and spatial Autocorrelation

I'm fitting GLMM's to roe deer count data derived from GPS locations based on a regular sampling grid with R. From what I could tell glmmTMB seems to be well suited for this kind analysis - especially ...
1
vote
1answer
131 views

What approach can I use to analyse zero-inflated, overdispersed, count data with very low replicates and a nested random effect?

I am having trouble with analysing some of my data. I'm trying to test the effect of a treatment with two levels (Treatment/Control) on the abundance of ants belonging to different dominance ...
2
votes
0answers
140 views

Maximal glmm converges but removing interactions leads to model convergence problems

I'm running a large negative binomial glmm, with a lot of zeros in my response, using glmmTMB in R. My model converges when I ...
2
votes
0answers
248 views

Diagnostic residuals for Beta GLMM weighted by sample size (Meta-analysis) using glmmTMB

I am conducting a GLMM for a meta-analysis using the beta distribution with the package glmmTMB. My response variable is a vector of correlations (No exact 0 or 1), but Fisher’s transformation fails ...
1
vote
0answers
379 views

Binomial GLMM for proportion (glmmTMB/lme4)

Hopefully this will be a straightforward question for anyone experienced with GLMMs. I'm trying to model aggregation of parasites on different locations on their host. I'd like to approach this by ...
3
votes
1answer
603 views

GLMM with poisson distribution for non-integer “count” data

excuse me if this is duplicated. I've poked around this and other sites and have found some good info about glmm's and Poisson distributions, however my case seems a bit different. I am currently ...
0
votes
1answer
154 views

Dispersion value with glmmTMB versus mgcv::gam()

Assume we parametrize the variance in a negative binomial regression model as: variance = mu(1+mu/theta). Fitting the model with glmmTMB, I check theta from: <...
0
votes
1answer
226 views

Fitting a model using glmmTMB

Let's say I've got 3 scaled quantitative features, and 1 target categorical feature. Each quantitative feature is independent from each other. If I use glmmTMB to try and fit a model for this I ...
2
votes
0answers
253 views

Can glmmTMB estimate this type of model?

I am trying to estimate a mixed effects model with a random effect that is subject to both cross-correlation across groups and auto-correlation over time within groups. Can this be done with glmmTMB? ...
2
votes
1answer
618 views

Interpretation and validation of glmmTMB for ecological count data

I have a couple of questions regarding the analysis of count data using glmms, specifically glmmTMB. I have a four year data set (starting Mar2013 – Dec2016) of insect count data, collected at weekly ...
0
votes
0answers
250 views

Modeling beta distributed data using glmmTBM

I have been trying to model this beta distributed data for a bit now with no success. It doesn't seem to be zero-one inflated visually, but I do have some ones in my data. Here is the description of ...
1
vote
0answers
2k views

Which of glmer or glmmTMB fits a binomial family mixed model with response in [0,1] - and what metrics help choose? [closed]

I have proportion data $Y \in [0,1]$. Without random effects, this is fit in glm without too much trouble, with family = quasibinomial to adjust the standard errors, although I actually bootstrap to ...
1
vote
1answer
501 views

Can I get an R-square value in a glmmadmb with negative binomial distribution?

I used the GLMMadmb function to asses the effect of three fixed factors (and two interactions) and two random factors on the abundance af a specie; my data had a negative binomial distribution. My ...
0
votes
1answer
495 views

Zero-truncated Poisson distribution in glmmTMB

I'm trying to use a zero-truncated Poisson GLMM using the R package glmmTMB. The documentation for this package says that zero-truncated Poisson can be specified, ...