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
1
vote
0answers
20 views

Modeling repeated cross sectional clustered data

I have repeated cross sectional data from convenience samples of students nested in schools nested in districts. I have data on student-level behavioral outcomes (binary) and school-level program ...
3
votes
0answers
22 views

Is there a joint test of model coefficients, effectively testing for main and interaction effects in quantile linear mixed model?

I am just reading this paper: Linear Quantile Mixed Models: The lqmm Packagefor Laplace Quantile Regression. Let us assume I have a repeated observation experiment, where I want to assess the effect ...
4
votes
1answer
29 views

Can I use different data types in a general linear mixed effects model?

I've become quite familiar with linear mixed effects models but I'm not very certain about their General counterparts. I have a data set which looks like the following: ...
3
votes
1answer
27 views

How can I construct the random effects model matrix from a mixed model formula

Let us say we have a mixed effects model formula. For example, in R using lme4, consider two formulas: Y~X1+X2+(1|fac) and ...
1
vote
0answers
67 views

Nested Experimental Design: Intuition about power?

I am planning a nested experimental design, where 1000 participants respond to one policy proposal coming from a 2^3 design (125 participants for each condition A x B x C). Yet, the policy proposal ...
2
votes
0answers
33 views

Fitting Joint Model with GLMM

I'm looking to fit a joint survival model (example). For those who are unfamiliar, joint survival models are Cox proportional hazard models where the covariates are allowed to be time-varying and are ...
3
votes
1answer
43 views

Between-subjects, factorial, crossed, cross-classified: all the same thing?

Suppose I have a test with $j$ items taken by $i$ persons. I wish to obtain the mean item score (y) taking into account that both items and person are a sample of ...
1
vote
0answers
13 views

Effects package equivalent for LCMM [closed]

The effects package helps in the analysis of predictor effects from LMER models. Is there an equivalent for LCMM models? (i.e. understand predictor effects of class ...
2
votes
0answers
22 views

Random coefficients and fixed effects

In a nonlinear model, for each time $t\in\{1,..,T\}$ and product $ j\in \{1,..,J_t\} $ individual $i \in \{1,...,I_{t}\} $ chooses an amount $y_{i,j,t}$ modeled as $ q_{i,j,t} = \frac{1}{\tau_j k_{j,t}...
4
votes
1answer
33 views

Interpret Negative-Binomial mixed-model output in R

I am modelling the number of jobs in a year, with a random intercept to account for regional variation. How do I interpret the model output when using the model to predict/ for inference? For example, ...
5
votes
1answer
32 views

Difference between Linear Mixed Regression and Generalized Estimating Equation Results

I am using commonly available iris dataset and trying to do following regression: PW ~ PL + SL + SW Since samples are taken from 3 "Species", this is kept as random or group variable. The ...
8
votes
1answer
88 views

Reading multilevel model syntax in intuitive ways in R (lme4)

Below, I have 3 lme4 longitudinal mixed-models. Throughout, y is the response variable, group...
1
vote
0answers
13 views

LmerTest::lmer degrees of fredom incorret

I had a good search but apologies if this has been answered elsewhere. I am using LmerTest::lmer to estimate a mixed effects model. I have 50 subjects (in three groups) and two measurements per ...
3
votes
1answer
23 views

How to select the family for a GLMM with non-normal, continuous data and lots of zeros

I'm new to using glmer's in the R package LME4. I want to run a repeated measures GLM for my data. The data is looking at a readout of an accelerometer and correlating to behaviour- so the readout has ...
0
votes
0answers
22 views

lme4 - nested time structure

I have a group of participants that performed measurements in 9 session. We performed 3 measurements per session of the same variable. Normally we would average these 3 measurements and call it a day, ...
1
vote
1answer
42 views

What to do with a singular fit with gls in R ? (mixed effect model and nested factors)

I am new to these kind of statistics and I don't understand the error I get since the same code worked before on an other set of data (with different levels in the factors). Here is my design. I have ...
0
votes
1answer
17 views

Comparing coefficients in between linear and linear mixed effects models

I have a naive question, but it will help me to get a better conceptual understanding of how the mixed-effects model works. Question: If I do linear regression and linear mixed-effects regression on ...
3
votes
1answer
29 views

Longitudinal regression for categorical data (possibly in R)

Suppose I have a categorical outcome variable (stand) from students' reading performance that is like: "Notapproach", <...
3
votes
1answer
37 views

Have I specified my random effects correctly in my lmer model?

I've run an experiment where participants (PP) viewed 40 quotes (Item) and rated them (Rating...
3
votes
1answer
28 views

How does data sparisty affect the predictive abilities of mixed linear models?

I am new to statistical modelling and I have a potentially silly question. I've been working with a mixed model where the design matrix of one of the categorical random predictors (...
3
votes
1answer
44 views

Using LMER fixed effects in LCMM

I am building a LCMM model, and trying to understand how to select the covariates for the model. Is it feasible to first use LMER with Anova (add critical parameter, measure loglikelihood between ...
0
votes
0answers
14 views

Creating a 2-level mixed model in SPSS to find predictors nested within subjects

I'm working with longitudinal data, and am using the mixed models function ins SPSS to look for predictors (level-1) nested within individuals (level-2). If I add the participant ID as "subject&...
3
votes
1answer
49 views

Book recomendation introducing multilevel models for a pure mathematician

Is there a good book on Multilevel models (random intercept, random slope, fixed effects, etc.) written for mathematicians which treat the theory rigorously? My background is essentially is in the ...
1
vote
0answers
23 views

unbalanced mixed-effect model (2 measures)

I am planning a study where participants perform a task lasting, say, 100 to 300 secs; its length is randomly drawn from a uniform distribution with increments of 1 sec. Is this appropriate or would ...
4
votes
1answer
34 views

Is my design nested or crossed? Question concerning specifying random effects with lmer in R

I've run an experiment where 120 participants (PP) viewed 40 quotes (Item) each (presented in Facebook format) and were asked to ...
0
votes
0answers
33 views

Different linear mixed model approaches for only estimating variance components once

I found these papers on linear mixed model with a single random intercept: 1. https://www.genetics.org/content/177/1/577.long Where they use an approach for implementing a linear mixed model, where ...
3
votes
1answer
34 views

Repeated measure clinical trial Linear mixed model

I am working on a clinical trial testing an innovative rehabilitation therapy on patients and I would like some suggestions on how to analyse the data. The study design is: 2-groups: conventional (n=...
8
votes
2answers
172 views

Why not always use generalized estimating equations (GEE) instead of linear mixed models?

I read about generalized estimating equations (GEE) here, here and at other sites. It is mentioned in first of above links that "the parameter estimates are nearly identical" for linear ...
2
votes
1answer
27 views

Standard error in multi-level models vs. non-multi-level models

Gelman & Hill (pp. 252-259) discuss "no-pooling" (single-level), and "partial-pooling regression" (multi-level) with no predictor ($section~ 12.2$). In almost all mixed-effects ...
3
votes
1answer
42 views

spaMM::fitme() - error troubleshooting and application to longitudinal data [closed]

I'm trying to fit a GLMM that accounts for spatial autocorrelation (SAC) using the spaMM::fitme() function in R. I have a longitudinal data set where observations were collected repeatedly from a ...
6
votes
1answer
65 views

Does sample size affect choice between fixed and random effect

I am analyzing data as given in this question: Should "City" be a fixed or a random effect variable? Here it is debatable whether "City" is to be kept as fixed effect or random ...
1
vote
0answers
39 views

Which model and distribution to use to fit continuous proportional data with random effects; glmmTMB, glmer, lme? I am getting errors with all 3

I am having trouble determining the most appropriate model to fit my continuous proportional data. I am analysing the proportion of time individuals were detected within an acoustic receiver array ...
14
votes
3answers
562 views

Should “City” be a fixed or a random effect variable?

I am analyzing data on "BloodSugar" level (dependent variable) and trying to find its relation with "age", "gender" and "weight" (independent variables) of ...
2
votes
1answer
40 views

Is this correct use of linear mixed model?

This is the current data I have I want to know if fixed factor A has any effect on C. That is, if A1 = A2 = ... = A5. I think I am trying to find a group difference, correct me if I am wrong. ...
2
votes
1answer
32 views

R - Data Simulation with Multiple Random Slopes

I am trying to run the following model: I(week^2):mutation_status + (week + I(week^2) | subject_id) , data = sim_dat) This is the output I ...
3
votes
1answer
32 views

Comparing model performance: do fixed and random effect regression models give different model ranking?

I am a graduate student in animal science. I am comparing linear models that fit covariates of var1 and var2. These two covariates are decomposed from one quantity say F (inbreeding level of animal). ...
1
vote
0answers
26 views

Multilevel hierarchical simulation? What model to use?

The problem: I have a dataset that I think could be deemed hierarchical. Assume that there are 1-100 ids, which all can have anywhere from 1-3 sub_ids. Both the top ids can have specific features that ...
4
votes
1answer
64 views

Non-normality in linear mixed models/GLMM

I have some data of time-depth profiles of whales. I want to model how the maximum depth of each dive (deepest point reached during a dive) changes between two dive types, foraging (if the whale feeds)...
0
votes
2answers
68 views

Correlation of two continuous variables but with clustered data

I want to correlate two changes in time, a change in microbiota with a change in some marker. There are several time points, so I have several differences in each participant. My idea is to see if ...
0
votes
0answers
46 views

Comparing lmer and LCMM (single class) models

I am modeling the same dataset using both lmer and LCMM. My understanding is that if I use class count of 1 for LCMM, the models derived from both methods should be very similar. However, as seen in ...
4
votes
1answer
145 views

Difference between Repeated measures ANOVA, ANCOVA and Linear mixed effects model

What is the best way to analyze these data: Subjects are divided in two "Group" (Treatment A and B). "Weight" is recorded before and 3 months after treatment. Outcome variable: ...
0
votes
1answer
36 views

lme4: prevent 'glmer' to have zero estimated random coefficient

I use the glmer function with the Poisson family from lme4. My simulated data are constituted of 3600 individuals, and a ...
1
vote
0answers
22 views

Preparing **probabilities** data for mixed effect modeling

I have two related problems i cant seem to find an online solution and would really appreciate any direction. I am modeling probabilities* as a function of different predictors, across 35 subjects. X1 ...
0
votes
0answers
22 views

glmmLasso vs. lmmLasso vs. LMMEN to reduce highly correlated predictors?

I have trouble choosing the correct model and parameters for my problem. I have around 20 experts who rated the quality of brain tumor segmentations for around 20 patients on a 1 to 6 star scale. I ...
1
vote
0answers
17 views

How to model repeated measurements with the same outcome in a Bayesian framework?

Can't think of a more accurate title, so I'll illustrate the problem with an example. I want to record temperature using cheap noisy sensors. I also have recordings from a gold-standard reference ...
1
vote
0answers
36 views

Estimating a paired samples t-test equivalent in mixed model with two random factors

I have data where 880 participants answered 10 questions at time 1 and at time 2. I want to use a mixed model and consider both participants (id) and questions (question) as random effects. I'm using ...
2
votes
2answers
53 views

Follow-up: Complete-pooling, no-pooling, and partial-pooling regression in R

This great answer demonstrates the concepts of "complete-pooling regression", "no-pooling regression", and "partial-pooling regression" (3 concepts) using simulated data ...
3
votes
1answer
24 views

How to interpret main effect with two interaction terms?

I have three variables in a multilevel model: Relationship Status (0 = single, 1 = not single) Living Arrangement (0 = alone, 1 ...
1
vote
0answers
41 views

Autocorrelation in linear mixed models (lme)

To study the diving behaviour of whales, I have a dataframe where each row corresponds to a dive (id) carried out by a tagged individual (whale). For each dive I calculate a series of parameters (...

1
2
3 4 5
84