Questions tagged [mixed-model]

Mixed (aka multilevel or hierarchical) models are linear models that include both fixed effects and random effects. They are used to model longitudinal or nested data.

Filter by
Sorted by
Tagged with
0
votes
1answer
23 views

How to study a fractional factorial design? [closed]

I wonder why a DoE/fractional factorial design isn't studied with the help of a linear mixed model? Or an Anova? How to analyze it in general is e.g. given here. Background: I will study several gas ...
0
votes
0answers
34 views

Mixed-effects model in lme4 with partial correlation of treatment and cluster

I have data from a randomized experiment, which is clustered at two different levels in the following form: So the situation is a bit unbalanced: There are N = 14 clusters of level 1, which all ...
0
votes
0answers
19 views

Random effects estimates using heuristic / numeric approaches

This is perhaps more a conceptual question. I'm using an heuristic algorithm (ABC: Artificial Bee Colony) to search solutions for a given model that can take additional factors such as numerical and ...
0
votes
1answer
38 views

d-prime as dependent variable in mixed effects model

d-prime refers to the sensitivity index in the signal detection theory, calculated as the z(probability of hit)-z(probability of false alarm). If I have to build a linear mixed-effects model with d-...
1
vote
0answers
20 views

Is It Valid To Calculate Model-Averaged Confidence Intervals In the Same Way As Model Averaged Predictions?

I'm fitting a series of mixed-effects models, and I'm trying to calculate the model-averaged predictions and their confidence intervals. If I have a set of $R$ models $\{M_1,...,M_R\}$ I know that ...
1
vote
0answers
24 views

How to encode Times within Days in Multi-level Mixed Model in R?

I have the following experiment: I tested 16 subjects on 4 different days with a (repeated) measurement every 20 minutes for a total of approximately 15 measurements/day. I have about 4 time varying-...
0
votes
1answer
25 views

Why are my confidence intervals much larger in glmmADMB than glmer.nb?

I'm plotting 3-way interaction terms from a negative binomial models, and tested the models in two packages to check my work and as a sensitivity analysis. I used the effect function to extract the ...
0
votes
1answer
39 views

How to interpret a GLMM

I am new to stats and have run a GLMM in R using the lme4 package. The model includes marine litter collected in KG, with fixed variables of population (all), wind direction, wave strength. Random ...
3
votes
2answers
62 views

Regression Modelling of Linear, Exponential, and Power Curves in R [closed]

Please note this is cross-posted: https://stackoverflow.com/questions/57982488/regression-modelling-of-linear-exponential-and-power-curves-in-r I am trying to model reaction time (and other) data ...
1
vote
0answers
8 views

Simulate Data for Power of Random Intercepts Model

I am interested in calculating the power of a cluster randomized clinical trial of a binary intervention ($T$=1 for treated and $T$=0 for control). I have a pretty set number of candidate clusters ...
0
votes
1answer
44 views

jointModelBayes output

Consider the following example from a workshop by Dimitris Rizopoulos workshop. We have the following joint model: \begin{equation} \begin{aligned} y_i(t) &= m_i(t) + \epsilon_i(t) \\ &= \...
1
vote
1answer
30 views

How to calculate individual covariances and residual covariances in a multivariate mixed model

I need enlightenment in calculating individual covariances and residual covariances in a multivariate mixed model. I'm going to use the dataset 'Owls', present in the glmmTMB package to replicate ...
0
votes
1answer
36 views

Can we model a bimodal response variable using a mixed effect model?

I have a response variable that is bimodal (basically, 2 normal distributions that are sticked together) and want to model it using a linear mixed effect model. Here is a quick example (in R): <...
1
vote
1answer
58 views

linear mixed effects models - overfit: how to calculate predictive R squared

I am using R to build the random structure of my model but I am ending up with a very complex model. Currently looks like this: ...
2
votes
2answers
106 views

Why are emmeans package means different than regular means?

I am analyzing a dataset with missing data using the lme4 package for fitting mixed models and calculating fitted means from it using package emmeans. I have a feeling it relates to the missing data ...
1
vote
2answers
50 views

How reliable is a linear model on log-transformed data

I have collected timing data in which the residuals are non-normally distributed. I log-transformed the data, and then conducted a linear mixed-model regression analysis. (The residuals from the log-...
0
votes
1answer
35 views

Comparing effect of treatment, measured across several time points

I have an experiment in which mice were treated with a drug (or mock treatment) and an enzymatic activity assay was then conducted at four time points, one before the treatment and 3 after the ...
2
votes
1answer
32 views

Is there a better way to compare Intraclass correlations using mixed models?

The situation is this: The lab I work for is building an intercept-only mixed model, in part to estimate the intraclass correlation related to a particular random effect. They want to build two of ...
2
votes
0answers
36 views

GAM model: Group-specific smoothers with different wiggliness of two random and nested factors [closed]

I aim to model the specific seasonal population fluctuations of several species. In particular, I have the abundance of individual along several years of 20 populations belonging to 5 species, and I ...
1
vote
2answers
38 views

Analysis of interaction with multiple levels in each factor (emmeans in mixed model)

I ran an experiment with treatment (3 levels: ctrl, A, B) as a between-subject factor and environment (4 levels: 1, 2, 3, 4) as ...
0
votes
1answer
26 views

bootstrapping mixed effect regression coefficients in statsmodels

I have a mixed effect model that looks like this: ...
1
vote
1answer
24 views

Help for possible nested mixed effect model

I'm super new to mixed effect models and I wanted to make sure I was interpreting R code correctly. I'm using the "lmer" function in the "lme4" R package to do my analyses. I'm interested in ...
0
votes
2answers
58 views

generalized linear model with log link using log transformed fixed/random effects?

I am modelling a longitudinal dataset consisting of a continuous response variable (mutation count) with a binary predictor (medical history, ie previous medications) while accounting for time and ...
0
votes
1answer
54 views

Time varying covariates in longitudinal mixed effect models

I am looking for some help with my analysis of longitudinal data with time-varying covariates. I am planning to use R and the lme4 package. However, I am happy to use Stata also. I am interested in ...
1
vote
1answer
39 views

post hoc pairwise comparison

I have a model testing whether the modifications to my texts (fixed factor: Modified) affect several measures (for example IA_FIXATION_COUNT). The Texts used in my experiments are 8, and when i want ...
0
votes
1answer
45 views

Mixed models in repeated measurement with one treatment

I have an experiment that includes 8 subjects during one treatment, measuring response variable. The hypothesis is that there is some correlation between AV and lactate during the treatment. Some ...
0
votes
0answers
28 views

Can a nested random effect be examined as interaction?

I have a dataset in R containing some experimental behavioral data with the following structure. SubjectID: 1, 2, 3, 4, 5... ...
1
vote
1answer
16 views

Using General Mixed Effects models to address pseudo replication

A common problem in animal studies is pseudoreplication of data points due to a limit in the number of animals available in a study population. I need to address any pseudoreplication and influence ...
1
vote
0answers
27 views

How do you evaluate the prediction accuracy of linear mixed models?

How does one evaluate prediction accuracy with uncertainty for linear mixed models? Let's say I do bootstrapping and do train/test each time, and want to generate confidence intervals for some ...
0
votes
1answer
42 views

Is different sample size okey for a Repeated measure-between Subject experiment?

I have data from a between-subject experiment (Repeated measures, two conditions). Condition A has 15 participants while condition B is with 19. The difference is due to missing data. My aim is to ...
2
votes
1answer
70 views

What exactly is meant by a singular fit of a mixed model, and why does it result in perfect correlations among random effects?

I understand a singular fit to be cases where a random effect has a variance of 0. Does this essentially mean that the model could not find a variance parameter for the random effect that did better ...
0
votes
2answers
38 views

Model specification in nlme: Random effects

My design has a total of 20 sites. 5 sites belong to each of four land covers: A, B, C and D. In each site, I have 5 sampling locations, 2 metres from each other. From each sampling location, I ...
1
vote
0answers
25 views

Correlations in nested dataset [closed]

My main objective is to perform a correlation between a fitness cost (ex: lag phase duration) and amount of resistance. I do, however, have a quite complicated data set. I performed evolution ...
0
votes
1answer
51 views

Modelling proportion data using GLMMs

I am having some trouble finding the correct way to analyse some data. I am trying to determine whether a certain treatment had an effect on frog calling. Frog calling was measured as presence or ...
4
votes
2answers
66 views

Why is $R^2$ so difficult to calculate for mixed models (both for the model as a whole and the fixed effects)? [duplicate]

I have been using a package to calculate $R^2$ values for mixed models. The documentation for the package has the following quote from Harry Singmann: "The fact that calculating a global measure of ...
1
vote
1answer
56 views

Residual diagnostic plot of mixed model

I am fitting a mixed-effects model with the following specification: ...
1
vote
1answer
41 views

Mixed effects model with between subjects dependent variable

I've got a dataset where I try to predict a between-subject dependent variable (continuous), the average number of times a participant made a mistake on a cognitive task, with a within-subject ...
0
votes
0answers
16 views

Derivation for mixed distribution, Poisson-Lindley

I want to derive the Poisson Lindley Distribution. $$ f_x(x|\lambda) = \frac{\lambda^{x-1}}{(x-1)!}e^{-\lambda}$$ $$f_x(x|p) = \frac{p^2}{(p+1)}(\lambda+1)e^{-\lambda p}$$ The Distribution of x, $...
9
votes
3answers
415 views

Random effects model handling redundancies

I am trying to deal with a time-to-event analysis using repeated binary outcomes. Suppose that time-to-event is measured in days but for the moment we discretize time to weeks. I want to approximate ...
0
votes
0answers
24 views

Cluster Bootstrap Mixed Model Contrasts

So I regularly make use of lme4 and lmerTest to fit Linear Mixed Models. I then do the post ANOVA contrasts via the emmeans (Estimated Marginal Means) package. However, I understand that for ...
0
votes
0answers
12 views

Random slope perfectly correlated with intercept even when I group-mean center the intercept?

On my original dataset, I ran a multilevel regression with an intercept and a variable. I found that the random slopes were perfectly correlated with the random intercepts. I figured I could get ...
1
vote
1answer
82 views

What does Deviance mean in lmer [duplicate]

Probably a rather silly question, but I would like to have a clear explanation of what deviance in linear mixed models (using lmer) is. For instance, how do I interpret it along AIC, BIC, and LOgLik ...
2
votes
0answers
25 views

Why are my DF for denominator so large? Reporting mixed model output

I've never used linear mixed effects models before, so I'm new to reporting the results. Following a paper that used the exact same procedures as mine (pre and post test of this specific task), I'm ...
3
votes
2answers
74 views

Explaining Fixed and Random Effects

Let's say that I am trying to predict the Sepal Length in Iris data from Sepal Width, ...
1
vote
0answers
12 views

Interpreting nested mixed effects modelling output [closed]

I am having difficulties in interpreting my R output for a multilevel model I have conducted using the NLME package. I'm looking to answer the following questions: 1) What are the predictors of ...
1
vote
0answers
40 views

Interpreting nested mixed effects modelling output

I am having difficulties in interpreting my R output for a multilevel model I have conducted using the NLME package. I'm looking to answer the following questions: 1) What are the predictors of ...
0
votes
0answers
18 views

Mixed model development structure

My boss believes the data that we are working with might be understood via a mixed model. I wanted to make sure I was designing the model correctly as well as having a couple of questions. We have ...
0
votes
0answers
8 views

Numeric variable as a nested fixed effect nested within the fixed effect of a 2-level factor variable in a Poisson GLMER?

Can a numeric variable be nested as a fixed effect within the fixed effect of a 2-level factor? In either case, I would really appreciate published sources that support any claims. I have a set of ...
0
votes
1answer
38 views

How to correctly use lmer for mixed-effects model?

I have data of an experiment where subjects (ID) have to perform 10 trials of a go/no-go task. I want to study the influence of ...
2
votes
1answer
56 views

random intercept, random slope, what's next?

Consider a mixed effects model with a random intercept. This means $$y_{ij} = b_{0i} + \dots \text{ fixed effects } \dots +e_{ij}.$$ Now, suppose that we group the observations with respect to time $...