Questions tagged [glmm]

Generalized Linear Mixed (effects) Models are typically used for modeling non-independent non-normal data (eg, longitudinal binary data).

Filter by
Sorted by
Tagged with
36
votes
3answers
47k views

How can I test whether a random effect is significant?

I am trying to understand when to use a random effect and when it is unnecessary. Ive been told a rule of thumb is if you have 4 or more groups/individuals which I do (15 individual moose). Some of ...
35
votes
3answers
47k views

Difference between generalized linear models & generalized linear mixed models

I am wondering what the differences are between mixed and unmixed GLMs. For instance, in SPSS the drop down menu allows users to fit either: ...
26
votes
2answers
19k views

Diagnostics for generalized linear (mixed) models (specifically residuals)

I am currently struggling with finding the right model for difficult count data (dependent variable). I have tried various different models (mixed effects models are necessary for my kind of data) ...
24
votes
2answers
18k views

Why do I get zero variance of a random effect in my mixed model, despite some variation in the data?

We’ve run a mixed effects logistic regression using the following syntax; ...
22
votes
2answers
19k views

How to apply binomial GLMM (glmer) to percentages rather than yes-no counts?

I have a repeated-measures experiment where the dependent variable is a percentage, and I have multiple factors as independent variables. I'd like to use glmer from ...
19
votes
4answers
18k views

How to assess the fit of a binomial GLMM fitted with lme4 (> 1.0)?

I have a GLMM with a binomial distribution and a logit link function and I have the feeling that an important aspect of the data is not well represented in the model. To test this, I would like to ...
18
votes
2answers
9k views

Random effect equal to 0 in generalized linear mixed model [duplicate]

Sorry if I'm missing something very obvious here but I am new to mixed effect modelling. I am trying to model a binomial presence/absence response as a function of percentages of habitat within the ...
16
votes
1answer
5k views

Meaning of a convergence warning in glmer

I am using the glmer function from the lme4 package in R, and I'm using the bobyqa optimizer ...
15
votes
1answer
8k views

How to fit a mixed model with response variable between 0 and 1?

I am trying to use lme4::glmer() to fit a binomial generalized mixed model (GLMM) with dependent variable that is not binary, but a continuous variable between zero ...
14
votes
1answer
3k views

How will random effects with only 1 observation affect a generalized linear mixed model?

I have a data set in which the variable I'd like to use as a random effect only has a single observation for some levels. Based on the answers to previous questions, I've gathered that, in principle, ...
13
votes
1answer
9k views

Calculating ICC for random-effects logistic regression

I'm running a logistic regression model in the form: lmer(response~1+(1|site), family=binomial, REML = FALSE) Normally I would calculate the ICC from the ...
12
votes
2answers
18k views

How to test for overdispersion in Poisson GLMM with lmer() in R?

I have the following model: > model1<-lmer(aph.remain~sMFS1+sAG1+sSHDI1+sbare+season+crop +(1|landscape),family=poisson) ...and this is the summary ...
12
votes
1answer
1k views

Overdispersion and modeling alternatives in Poisson random effect models with offsets

I have run into a number of practical questions when modeling count data from experimental research using a within-subject experiment. I briefly describe the experiment, data, and what I have done so ...
11
votes
1answer
11k views

Marginal model versus random-effects model – how to choose between them? An advice for a layman

In searching for any info about marginal model and random-effects model, and how to choose between them, I have found some info but it was more-or-less mathematical abstract explanation (like for ...
11
votes
1answer
240 views

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 ...
11
votes
1answer
2k views

How do you deal with “nested” variables in a regression model?

Consider a statistical problem where you have a response variable that you want to describe conditional on an explanatory ...
11
votes
2answers
2k views

Generalized Linear Mixed Models: Diagnostics

I have a random intercept logistic regression (due to repeated measurements) and I would like to do some diagnostics, specifically concerning outliers and influential observations. I looked at ...
11
votes
0answers
2k views

Gamma hurdle model for continuous response

I am modelling invertebrate.biomass ~ habitat.type * calendar.day + habitat.type * calendar.day ^ 2, with a random intercept of transect.id (50 transects were repeated 5 times) My response is zero-...
10
votes
1answer
8k views

What are Hommel Hochberg corrections?

I have recently been introduced to to Hommel Hochberg corrections. I am trying to find a simple explanation about what this actually is/does, but am having no luck. Can anyone please give a brief and ...
10
votes
3answers
11k views

Generalized linear mixed models: model selection

This question/topic came up in a discussion with a colleague and I was looking for some opinions on this: I am modeling some data using a random effects logistic regression, more precisely a random ...
10
votes
3answers
21k views

Fixed vs Random Effects

I have very recently started learning about Generalised Linear Mixed Models and was using R to explore what difference it makes to treat group membership as either fixed or random effect. In ...
10
votes
1answer
9k views

Why do Anova( ) and drop1( ) provided different answers for GLMMs?

I have a GLMM of the form: lmer(present? ~ factor1 + factor2 + continuous + factor1*continuous + (1 | factor3), family=binomial) When I use <...
9
votes
1answer
18k views

Fitting a binomial GLMM (glmer) to a response variable that is a proportion or fraction

I'm hoping somebody can help with what I think is a relatively simple question, and I think I know the answer but without confirmation it has become something I just can't be certain of. I have some ...
9
votes
1answer
7k views

Help interpreting count data GLMM using lme4 glmer and glmer.nb - Negative binomial versus Poisson

I have some questions regarding specification and interpretation of GLMMs. 3 questions are definitely statistical and 2 are more specifically about R. I am posting here because ultimately I think the ...
9
votes
3answers
275 views

Bacteria picked up on fingers after multiple surface contacts: non-normal data, repeated measures, crossed participants

Intro I have participants who are repeatedly touching contaminated surfaces with E. coli in two conditions (A=wearing gloves, B=no gloves). I want to know if there's a difference between the amount ...
8
votes
4answers
464 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 ...
8
votes
1answer
2k views

Should I exclude random effects from a model if they are not statistically significant?

Should I include random effects in a model even if they aren't statistically significant? I have a repeated measures experimental design, in which each individual experiences three different ...
8
votes
2answers
30k views

r glmer warnings: model fails to converge & model is nearly unidentifiable

I have seen questions about this on this forum, and I have also asked it myself in a previous post but I still haven't been able to solve my problem. Therefore I am trying again, formulating the ...
8
votes
1answer
9k views

How to account for repeated measures in glmer?

My design is as follows. $y$ is Bernoulli response $x_1$ is a continuous variable $x_2$ is a categorical (factor) variable with two levels The experiment is completely within subjects. That is, ...
8
votes
1answer
2k views

Resolving heteroscedasticity in Poisson GLMM

I have long-term collection data, and I'd like to test, whether the number of animals collected is influenced by weather effects. My model looks like below: ...
8
votes
1answer
8k views

Model selection: can I compare the AIC from models of count data between linear and poisson models?

I am modeling count data (with offset / exposure parameter). My modeling strategy is use of a Poisson model and a negative binomial regression model. I compare model AICs, which are about -760 for my ...
8
votes
1answer
475 views

Suspiciously high shrinkage in random effects logistic regression

Consider the following simple example: ...
8
votes
1answer
639 views

How close to zero should the sum of the random effects be in GLMM (with lme4)

I'm using the lme4 package in R to do some logistic mixed-effects modeling. My understanding was that sum of each random effects should be zero. When I make toy ...
8
votes
1answer
2k views

Likelihood and estimates for mixed effects Logistic regression

First let's simulate some data for a logistic regression with fixed and random parts: ...
7
votes
3answers
354 views

Can I test for correlation between variables before standardize them?

What I want to do is to construct GLMM's to evaluate resource selection, and I have a set of variables (some representing distances and others representing % of land cover). Can I test for ...
7
votes
2answers
93 views

Confused about meaning of subject-specific coefficients in a binomial generalised mixed-effects model

In A Comparison of Cluster-Specific and Population-Averaged Approaches for Analyzing Correlated Binary Data, Neuhas, Kalbfleisch, and Hauck state: "With the cluster-specific approach, the probability ...
7
votes
1answer
978 views

GLMM overfitting solutions

in GLMM faq page http://glmm.wikidot.com/faq there is a statement about overfitting: "One alternative (suggested by Robert LaBudde) is to "fit the model with the random factor as a fixed effect, get ...
7
votes
1answer
519 views

GLMM and two slopes

My outcome variable is binomial, and I have 11 independent variables and a time variable. The time variable has different slopes, so I fixed it to time-before and <...
7
votes
1answer
6k views

How to assess overdispersion in Poisson GLMM, lmer( )

I have a GLMM with Poisson distribution and random spatial block. My experimental design is 2x2 factorial, with 4 blocks, resulting in 16 total data points. Here is the specification of the model in R ...
7
votes
2answers
3k views

How many observations do you need within each level of a random factor to fit a random effect?

I'm trying to analyse some data from a set of bird surveys. My response variable is "bird abundance", which is the number of birds counted over a five-minute period. These five-minute counts were ...
7
votes
1answer
2k views

Are $R^2$ for GLMM useful for modelers but not necessarily for readers?

The short version: 1)Are there any published critiques of the use of $R^2$ for GLMMs, in particular the popular approach of Nakagawa & Schielzeth (2013) A general and simple method for obtaining $...
6
votes
3answers
323 views

Temporal analysis of variation in random effects

I am looking at patient data where the main outcome of interest is mortality within 30 days following hospitalisation with an emergency condition. I am working on data from 2003-2017, with ...
6
votes
2answers
293 views

Metric as straightforward as R^2 for Bayesian models

So, the beauty of the $R^2$ in linear models or the deviance-based pseudo-$R^2$ from GLMs is their intuitive interpretation for non-specialists. There's also some nice developments on this front for ...
6
votes
1answer
2k views

Testing significance of a random effect glmmADMB model

Below is the output from a model of novel object test scores fit with the nbinom1 (quasi-Poisson) option in glmmADMB. I used ...
6
votes
1answer
2k views

How to calculate estimated proportions and their confidence intervals from a mixed model?

I have an experiment with two treatments. It is a split plot experiment, with the structure Block/Treatment1/Treatment2. Each treatment has 2 levels. The dependent variable is presence/absence data ...
6
votes
1answer
172 views

Interpretation of fixed effect coefficients from GLMs and GLMMs

I am currently interpreting some glm's and glmm's based on distributions with log link functions (gaussian - log, and negative binomial) and have started going in a bit of a loop regarding the ...
6
votes
2answers
9k views

Should I use Poisson distribution for non-integer, count-like data?

It's my first question here, I hope I'll ask it correctly. I am trying to find out how to analyse non-integer, count data (yes!). I am looking at the effect of a given treatment on habitat suitability ...
6
votes
2answers
803 views

Translate glmer (lme4) model specification into MCMCglmm

I am having some computational trouble estimating the following model with the glmer function in lme4: ...
6
votes
2answers
3k views

extremely left-skewed response variable - how do I model this dataset?

This is a histogram showing my response variable. The response is # (or proportion? or percent?) of aphids eaten off of cards in fields, to model predation by natural enemies. Predictors: fixed ...
6
votes
1answer
1k views

Do I need more than one random slope?

When constructing a GLMM in R, do I need more than one random slope if I "see" that slopes differ for multiple continuous variables? In my case, I am analysing the number of plant species (...

1
2 3 4 5
14