Questions tagged [glmmtmb]
R package to fit linear and generalized linear mixed models with various extensions, including zero-inflation.
210
questions
0
votes
0
answers
18
views
How to extract the correct unit decrease and confidence intervals from glmmTMB zero-inflated (count) model?
I am using this model to calculate the unit decrease of number of fledged birds (as a count) by a certain percentage of increase in ISA levels (percentage of impervious surface areas), this is the ...
0
votes
0
answers
11
views
LMM for Repeated Measures tree ring chronology
Having my first go at R and stats.
I sampled and analyzed tree rings for different measures (width, density, etc.). There are 3 treatments, 3 plot per treatment, and 5 trees per plot. The ring time ...
1
vote
1
answer
46
views
glmmTMB truncated models with zero inflation
everyone. I am fitting a glmm model using the R library glmmTMB for predicting a count response variable with excess-zeros and overdispersion (...
0
votes
0
answers
12
views
Back-transform binomial and betabinomial to counts with emmeans
My first outcome is a bounded count (range = 0-5, not zero-inflated, not overdispersed), so I specified a model using a successes-failures matrix and a binomial distribution:
...
2
votes
1
answer
43
views
How to interpret odds ratios by emmeans for glmmTMB-beta
I fit this mixed model with beta for the response variable: photochemical efficiency or Fv/Fm and the predictor variables are categorical:
...
0
votes
0
answers
20
views
Extract some modeled values from glmmTMB object
I modelled some dummy data in glmmTMB package in R:
...
0
votes
0
answers
15
views
glmmTMB profile argument, what does it do?
I tried running analysis using glmmTMB with profile=TRUE and the model that previously wasn't converging, now converging, anyone knows what assumptions does this parameter "profile" takes ...
0
votes
1
answer
35
views
obtaining a goodness of fit indices for an analysis with tweedie distribution
I performed an analysis specifying a dependent variable with a tweedie distribution using the glmmTMB package in R. I got several fit indices, specifically: AIC, BIC, Logliklihood.
What is the most ...
0
votes
0
answers
15
views
Significance in ZINB GLMM disappears when par1 * par 2 is used instead of par1 : par2 in R [duplicate]
I am working with a zero-inflated negative binomial model in R, using the glmmTMB package. My main goal is to investigate if there is a significant difference in the amount of times a grassland field ...
0
votes
0
answers
14
views
Dyadic reciprocity for binary outcome in asymmetric block design
I am trying to estimate dyadic reciprocity in a binary outcome collected with asymmetric block design (speed-dating where each person indicates whether or not they are interested in a second date with ...
0
votes
1
answer
46
views
Specify a correlation between two cross-classified random variables in a mixed-effect model
I posted this question in a different version on R-sig-mixed-models and received no reply. I am trying my luck here. I am trying to emulate an ANOVA-based approach to analyzing round-robin data with a ...
0
votes
0
answers
41
views
How do I move forward to find a better model fit, help interpreting DHARMa residuals
I am trying to test if there is an effect on number of individuals depending on the proportion of a certain land use type and its management. But I don't find a model with a good fit. There seems to ...
1
vote
0
answers
33
views
GLMM optimised with CG gives empty warning, diagnose() finds no problem
I am running the following code for a ZINB GLMM, using the glmmTMB package in R:
...
1
vote
1
answer
39
views
How to specify random slopes when random effects are nested or crossed
I'm trying to run a model which has 3 random effects. Its data on an animal species and the random effects are 'group', 'mother' and 'individual'. Individual should be nested within mother, and then ...
1
vote
1
answer
30
views
Is this GLM approach appropriate for binary data and determining difference between 8 groups?
I have been given a dataset to analyze looking at some herbicide treatments for invasive trees in three states with 3 sites in state 1, 2 sites in state 2, and 1 site in state 3. We hope to answer ...
0
votes
0
answers
48
views
Why would a model indicate overdispersion without random effects but underdispersion with random effects? (and how to handle)
Overview: In my model building process, I fit both GLMs and GLMMs. I noticed that the GLMs suggested overdispersion in the data, while the GLMMs suggested underdispersion. How can I make sense of this,...
0
votes
0
answers
14
views
Binomial model with glmmTMB library [duplicate]
I proposed the following binomial model, with the glmmTMB library, because I want to evaluate if there are differences between the proportions of infection by a given parasite for different ...
0
votes
0
answers
26
views
How can I best formulate my glmm if i want to test within individuals and within context for these individuals?
I am a beginner in using glmm, I have a question about which structure to test "within individual and within context". I have collected vocal data on 12 different individuals (animals) in a &...
0
votes
0
answers
44
views
How to deal with overdispersion with glmmTMB for generalized linear models
I'll try to make it as brief as possible.
I'm trying to fit a glm to echolocation clicks count data using the glmmTMB function. I started with a Poisson glm and ...
0
votes
0
answers
41
views
ar1 and glmm with glmmTMB?
I wonder if I'm not actually totally barking up the wrong tree. I have a longitudinal dataset with 10 measurement time points ("mtp"), the subject variable is "id" and I want to ...
1
vote
1
answer
96
views
Dominance analysis with a random-effects beta regression: nested random effects throw error
The goal
I want to run dominance analysis on a mixed-effects beta model, to approximate the relative importance of a set of predictors (2 factors, 1 scaled continuous, 1 continuous with splines). The ...
0
votes
0
answers
52
views
How to account for predictors of different lengths or uneven distribution in GLMs?
I have different lengths/distribution for three predictors: year, location and cultivar. I ...
1
vote
1
answer
49
views
My GLM runs with no warnings but when a GLMM with random effect, 3 warnings
I have a dataset with 4 columns of interest:
Event (1 or 0, binary)
Nymph (Y or N, categorical)
Date (Dates from 2023-04-03 to 2023-05-02)
Tag (categorical, individual IDs (77 distinct Tags)
I have ...
1
vote
1
answer
35
views
Can I use log10(time) as an offset in a GLMM?
I'm trying to analyze a dataset but am running into a problem with one of my models. The particular set of data I'm working with is species richness data (number of species seen during each sampling ...
0
votes
1
answer
647
views
Interpretation of glmmTMB output for zero-inflated negative binomial regression
I fitted, using glmmTMB R package, a zero-inflated negative binomial GLMM, with offset and a random factor, to investigate which variables could explain animal ...
2
votes
1
answer
57
views
Is it appropriate to visualize multiple glm models (of different families) in the same plot?
I am assessing the effect of 5 predictor variables on species abundance. I have created 12 generalized linear models in R that have the same response and five predictors. Rather than run a complex ...
1
vote
1
answer
173
views
Inverse and log link give opposite results in Gamma GLM
I'm fitting a Gamma GLM using glmmTMB and noticed that choosing link = "log" or ...
0
votes
0
answers
19
views
Multilevel mixed modelling of ratio values in R
I have a dataset of 10 columns and approx 4,5k rows, each row representing a sampling point. As sampling points share some common features, a categorical variable with 27 levels were created to ...
0
votes
0
answers
109
views
How to report emmeans results when p value = 1.00?
I am working with data of vegetation cover (proportions) for different height strata (0-5, 5-15, 15-30, >30 cm, and also bare ground) amongst four different sites and two different time periods (...
1
vote
1
answer
68
views
Estimating Exponential Decay Rate and its confidence interval from Beta Regression Odds Ratio fit
I am working with a random variable that is bounded between 0 and 1, and its mean decreases exponentially over time. I am seeking to estimate this exponential decay rate with its corresponding ...
0
votes
0
answers
126
views
Use of t_family distribution in glmmTMB
I am trying to use t_family(link="log") distribution from the glmmTMB package. The package allows fixing the shape parameter using ...
0
votes
0
answers
39
views
Whether my model follows the QQ plot and DHARMa residual in glmmTMB?
I ran this code and found the result. Could you please help me to figure out my model follows DHARMa residual?
...
0
votes
1
answer
107
views
Which one (conditional or dispersion model) is the final result in glmmTMB? [closed]
Please help me to figure out the final result in a glmmTMB. I used this code
model1<-glmmTMB(ctmax ~ lat+ (1|site), dispformula=~lat,data=data)
summary(model1)
...
1
vote
0
answers
81
views
Attributing variance to fixed and random effects / partial pooling in glmmTMB
I have a dataset with counts of birds in two locations over time, and am interested in describing the difference in trends in bird counts between these locations. The counts are conducted by multiple ...
1
vote
1
answer
66
views
Zero inflation formulas do not improve zero inflated model (GLMM) [closed]
I'm a student trying to adjust a count data GLMM to zero inflation using function glmmTMB.
Model family is nbinom1 family (better AICc compared to nbinom2 and poisson).
My data contains about 20 % ...
1
vote
0
answers
97
views
Overdispersion in a beta regression? (DHARMa package)
I'm trying to run a beta regression to predict my dependent variable Consistency, which has values between 0 and 1.
Here is the distribution of Consistency values in my dataset:
I originally tried ...
0
votes
0
answers
51
views
Is there a way to reassemble smooth terms from mgcv in glmmTMB?
I am in need of a ZI genpois model in glmmTMB for my analysis (modelling nested annual bird counts ~ weather covariates). A random slope/intercept glmmTMB model (1 + year | site) cannot resolve the ...
0
votes
0
answers
37
views
(Ab)Use of offset() in Poisson GLM to weight the damaging effect of counted insect stages
According to A.F. Zuur et al. (2009) in 'Mixed Effects Models and Extensions in Ecology with R', p. 239ff and this post: When to use an offset in a Poisson regression?, ...
2
votes
1
answer
242
views
Spatial autocorrelation correction with glmmTMB
I am currently working on a dataset (count data) in which one observation corresponds to one day of monitoring at a site.
The overall protocol is to monitor groups of sites along transects. Almost all ...
0
votes
0
answers
24
views
GLMM on temporally correlated count data from a designed agricultural experiment
I have carried out a designed agricultural experiment with two treatments and recorded the effect on the abundance of a pest insect on three dates. The field experiment was divided into four blocks ...
2
votes
0
answers
35
views
Analysis of spatially correlated count data from a designed agricultural experiment
I have carried out a designed agricultural experiments with two treatments and recorded the effect on the abundance of a pest insect. The field experiment was divided into four blocks with two plots (...
2
votes
2
answers
119
views
Is it possible to calculate x-intercept from a mixed model?
I understand that the x-intercept can be calculated using $y = mx + b$ for a linear model. I am unsure if this is statistically appropriate for a mixed model with count data, given that counts cannot ...
0
votes
1
answer
180
views
Clustered vertical lines in the plot(model, residuals)
I am stuck in the diagnostics of my model, and I am looking for advice on what to do.
My data frame goes like this
...
3
votes
3
answers
873
views
How to extract the residual and null deviances from a glmmTMB object (to calculate D2, the deviance explained)?
The context is about the use of a given model deviance (often referred to as “Residual deviance” in R) and that of its “Null deviance” to calculate D2, the deviance explained for models with non-...
0
votes
0
answers
72
views
glmmTMB missing values in summary output
I have greated a model using glmmTMB and as I am interperating the results is am having trouble with the intercept. Please let me know if I am going in the right direction.
I have three types of ...
0
votes
0
answers
119
views
piecewiseSEM standardized coefficients not returned when using glmmTMB model
I would like to include a beta-regression model (using the package glmmTMB) via the piecewiseSEM package.
The beta-regression model looks like this:
...
0
votes
0
answers
165
views
Parameterization of the beta-binomial family Glmmtmb
I have trouble understanding the documentation for the glmmtmb package (https://cran.r-project.org/web/packages/glmmTMB/glmmTMB.pdf)
On page 26, in the details on the beta-binomial distribution, it ...
0
votes
0
answers
27
views
Stuck on interpretation/validation of GLMM results
I am using glmmTMB in R to identify which weather variables (n=5) most influence annual bird counts (n=5 responses) from different monitoring sites. So far, I have ...
1
vote
0
answers
79
views
(Normality) assumptions of logistic multilevel model (glmmTMB)
I have a dataset with patient data in a psychiatric hospital. Some patients had more than one stay, so the observations are not completely independent. I therefore used a multilevel model (in R with ...
0
votes
0
answers
84
views
Inclusion of candidates in model averaging with GLMMs
I am using GLMMs to examine the influence of 5 weather variables on different biological count variables in R. With n=5 weather variables and modelling main effects only, I have 32 candidate models (...