186 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
1
answer
167
views
Custom ratio contrasts with emmeans and glmmTMB
I'm running a glmmTMB model with a gaussian distribution. I'm putting together custom contrasts - I need to compare one level of factor (exposure) with the average of several other levels (baseline). ...
0
votes
0
answers
64
views
How to fix error ranForm[ranForm == namBlk][[x]] : subscript out of bounds from setting start method in glmmTMB? (with reproducible example data)
library(glmmTMB)
library(dplyr)
model <- glmmTMB(menthlth ~ sex + medcost + X_educag + internet + X_race + smoke100 + cellphone + (1 | district) + status
+ children + ...
1
vote
0
answers
53
views
What does "Error in UseMethod("mutate")" mean, returned from `DHARMa::simulateResiduals()"?
library(glmmTMB)
library(dplyr)
library(DHARMa)
ml <- glmmTMB(menthlth ~ sex + medcost + ...,
ziformula = ~ sex + medcost + X_educag + internet + ...,
data = ...
0
votes
0
answers
28
views
How to define correlation structure for relational data in glmmTMB?
I have relational data, i.e. observations for pairs of objects. More specifically these are migration rates between plant populations, which I would like to explain by a predictor. The migration rates ...
0
votes
0
answers
28
views
Can we force bootMer to ignore convergence warnings?
I fitted a complex betabinomial model with very large values for both variables comprised in the response variable (cbin(Methylated_C, unMethylated_C)).
model <- glmmTMB( ...
1
vote
0
answers
91
views
How to get estimated expected values in glmmTMB?
Is there a way to obtain estimated expected values from a glmmTMB object? Specifically, if Y is the response vector and X,Z are design matrices for fixed and random effects respectively, I want an ...
1
vote
0
answers
66
views
Estimated covariance matrix in glmmTMB
I would like to obtain the estimated covariance matrix of the (random) linear predictors from a glmmTMB object in R, or at least the diagonal of that matrix, that is, the variances.
In lme4 the full ...
3
votes
1
answer
134
views
glmmTMB with smooth terms and random slopes
I'm a newb using glmmTMB, especially with smooths. The first model (m1) gives me what I expect: parallel smooths for each site since there are random intercepts for site.
My question is: is the second ...
2
votes
1
answer
164
views
glmmTMB: start a new optimization at the optimum of previous model
Suppose I have the following model:
library(glmmTMB)
Owls <- transform(
Owls,
Nest = reorder(Nest, NegPerChick),
NCalls = SiblingNegotiation,
FT = FoodTreatment
)
fit_zipoisson <- ...
0
votes
0
answers
39
views
Retaining random effects in buildglmmTMB
I am using buildglmmTMB to build a model for several different taxa. I have 700 ish taxa and ~10 effects. I have a script that loops through all the taxa and applies buildglmmTMB to each taxa ...
0
votes
0
answers
58
views
Any known changes to glmmTMB since 2023 that would alter model fit?
I used glmmTMB to run GLMMs with a beta distribution to evaluate the proportion of time an animal spends doing a behavior. My observations were of different lengths, and I weighted the observations ...
0
votes
1
answer
119
views
Print mice imputed glmmTMB conditional and zero-inflated model side-by-side with modelsummary
Consider the following estimate:
library(glmmTMB)
library(mice)
Owls <- Owls
Owls[sample(1:nrow(Owls),10), "ArrivalTime"] <- NA
predictorMatrix <- quickpred(
Owls,
include = ...
4
votes
1
answer
100
views
glmmTMB issue with number of observations and groups
I have a dataset with 125 animals across 3 sites and 100500 observations. Both show up properly when looking at the structure of the data but when I run the model with an updated data frame (I added a ...
0
votes
0
answers
116
views
problem with glmmTMB with a matern for spatial autocorrelation
I have a dataset of bird counts, on a spatial grid, with environmental and prey data.
I have applied a correction factor for distance from observers, so I have semi-continuous values, with lots of 0's ...
0
votes
0
answers
132
views
Can I use the segmented package with a generalized linear mixed model?
I am working on a grant proposal evaluating the effectiveness of an intervention on several different groups of hospitals and after some statistical consulting have landed on using a generalized ...