All Questions
3,532 questions
0
votes
1
answer
232
views
Multilevel analysis - interpretation not significant at level 1
I'm doing a multilevel analysis for the first time for my master thesis.
The goal of my study was to create behaviour change through an intervention. Participants are measured for behaviour at 3 ...
0
votes
0
answers
10
views
Statistical Inquiry. Overdispersion issue or abundance of 0s
Trying to go over some data and its half presence absence while the other half is count data. The model I've been working on lately is a mix of lmer and glmer.nb as that seems to be the approach for ...
1
vote
0
answers
51
views
Opposite results using Bayesian (STAN) vs Multilevel model (nlme). How is this possible?
My datasets contains the median wages and the cumulative installed wind-capacity for 4000 counties over a period of 20 years. The wages tend to rise over the period and the capacity tends to highly ...
1
vote
0
answers
38
views
How to estimate population variance from a mixed model with a categorical variable?
I supposed it is a basic question, but I'm stuckle on it and I can't find the solution.
I have a date base with the slurry dry matter content from different pig production stages (CATEGORY), also, ...
1
vote
1
answer
98
views
Calculate inter-rater noise using Kahneman et al. (2021) approach
I need help calculating signal and noise based on the method described by Kahneman et al. (2021) in their book "Noise." They provide a technique for quantifying noise between raters ...
0
votes
1
answer
35
views
Fitting a Nonlinear Mixed Model
I’m trying to fit a nonLinear Mixed Model (nLMM) to test whether the abundance of certain organisms was affected by the sampling period after an event that caused a significant increase.
The data show ...
2
votes
2
answers
3k
views
GEE vs LME, non-normal distribution
I have a question about statistics theory.
I have longitudinal, repeated measures data where the response variable is skewed right. Using R, I ran a linear mixed-effects model (good for longitudinal, ...
1
vote
1
answer
409
views
nlme ignoring certain control arguments to nlminb
Issue: Do constrained optimization of parameters in nlme::nlme
I'm trying to fit a non-linear mixed effects model using nlme::nlme, which can use 2 optimization schemes: stats::nlminb or stats::nlm.
...
9
votes
2
answers
990
views
Should I control for random effects of participant in an individual differences design?
I'm trying to analyse a survey study in which I'm interested in the way that individual differences between my participants influence how they respond to my stimuli. The stimuli are pieces of writing ...
3
votes
2
answers
108
views
R: How to fit a linear mixed model with a custom covariance structure for two random intercepts
Suppose I have a dataset with repeated measurements on q clusters. I want to fit an LMM with two random intercepts, on the same cluster, with a non-diagonal covariance structure on the random effects (...
4
votes
0
answers
281
views
GLMM and BLUPs: high correlation between random effects in a logistic GLMM
Background:
In an experiment, subjects had to choose whether they wanted an immediate reward or to wait for a larger reward (dichotomous dependent variable: yes/no). This choice was made multiple ...
1
vote
1
answer
228
views
Formulating multilevel model with nested repeated measures within patients
I have an experiment with two fixed factors (repeated 2 x 2 design)
Between-factor: Treatment Group vs. Control Group (TREAT)
Repeated-factor: Pre-Treatment vs. Post-Treatment (TIME)
The dependent ...
7
votes
2
answers
3k
views
Modelling a binary outcome when census interval varies
For a current piece of work I’m trying to model the probability of tree death for beech trees in a woodland in the UK. I have records of whether trees were alive or dead for 3 different census periods ...
1
vote
1
answer
468
views
Effect size for fixed effect variable with >2 levels binomial glmm (lme4)
I have a mixed effects model with a binomial outcome which I constructed using glmer from the lme4 package in R. In the output ...
1
vote
1
answer
1k
views
Gamm residuals patterns: temporal and spatial
I'm trying to fit a GAMM model with this dataset, which can be downloaded here: https://ufile.io/8umh6 .
The dataset consists of 60 pixels sampled in two different areas: BAR and MON, 30 for each one. ...
1
vote
1
answer
48
views
Estimating mixed model with identical response value but different covariate values within a pair
Say we have a dataset with individuals. Each individual performed a task, either in solo or with another individual (variable condition), and we measured the ...
7
votes
3
answers
481
views
If the categorical variable is retained in my final model in R, then why does the post hoc analysis say the levels do not differ?
I am performing model selection in R with the anova() function, and my categorical variable was maintained in my final model, but when I did a post hoc analysis with the emmeans() function, it told me ...
3
votes
2
answers
440
views
How to change variance-covariance matrix in mixed models?
I'm currently trying to do power calculation using SIMR package in R.
To start off, I first created the following model which defines my study design with simulated output y:
...
1
vote
1
answer
3k
views
Decision to center fixed effects in GLMMs in lme4
I'm constructing a GLMM using lme4 in R, and am unsure as to when it is and isn't best practice to center fixed effects.
For this model (with logit link), for example:
...
1
vote
1
answer
246
views
Rank deficient mixed model - why is a particular interaction excluded?
I am analysing a dataset that has 20 sampling sites, each sampled five times (T1-T5) to measure the continuous response variable ('resp'). There is a continuous predictor ('covar') that was measured ...
0
votes
0
answers
11
views
DHARMa bootstrap testOutliers unexpected p-values
I am checking the assumptions of multiple univariate logistic mixed models each with a predictor and covariates.
Due to the following error:
...
1
vote
0
answers
29
views
Nested design with fixed and random effects: Is my R model correct?
I am trying to analyze a nested experimental design in R, but I am unsure whether I am approaching it correctly. I have a following data:
Set
Sample
Repet.
Response
1
1
1
y1
1
1
2
y2
1
2
1
y3
1
2
...
4
votes
0
answers
73
views
Major discordance between uncertainties estimated by `predictInterval()` and `bootMer()` for binomial GLMM with cloglog link
We have been using predictInterval() from the merTools package to bootstrap uncertainty for binomial GLMM models (complementary ...
1
vote
0
answers
69
views
simr Failing to Run, "observed power calculation"
I am analyzing simulated delay-discounting data. The response variable is reaction time in milliseconds. K is the scaling factor describing how much value is affected by delay. College Year is from 1-...
0
votes
1
answer
217
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 ...
5
votes
2
answers
107
views
Repeated measures within participant
I'm trying to learn linear mixed effects models and how to estimate them using the R package lme4 and I am confused about some aspects.
I have a dataset where a ...
2
votes
1
answer
24
views
LMEM - When is it okay to not treat repeated measures as a random effect? And other related questions
Design: I have 3 groups, each subject was tested 3 times (3 trials) per time point, on three different time points.
The Independent variables are: Group (A,B, or C), Trial (1, 2, or 3), and Time (0, 2,...
0
votes
1
answer
49
views
lmerMod vs lmerModLmerTest - what are the differences and which is correct?
I have three trials, want to know if the order of trial affected the outcome. I was checking my work with ChatGPT and noticed a discrepancy between their results and mine. This is the dummy code from ...
3
votes
2
answers
604
views
Is setting a certain covariance structure between random effects and zeroing R equivalent to setting this structure exclusively in residual matrix?
I'm wondering whether setting, say, a compound symmetry covariance structure between random effects and setting the residual covariance to 0 is effectively the same as not using the random effects G ...
3
votes
1
answer
303
views
Finding the optimal structure of fixed / random effects in a 3 way full factorial repeated measures design with nlme/lme4
I’m looking for help in finding the best / optimal structure of fixed and random effects in my repeated measures experiment data along with an explanation on why do I choose one solution over the ...
0
votes
1
answer
221
views
Different p-values for simple slope analysis after dummy coding and contrast coding using robust lmer
I want to average the effect of some continuous predictors on the outcome variable and so I used contrast coding as here (https://towardsdatascience.com/how-to-correctly-interpret-your-continuous-and-...
0
votes
1
answer
1k
views
lme for multiple groups comparing treatment vs control
I would like to check for differences in growth rate between groups. I have three main groups miRs and for each group I have a ...
1
vote
1
answer
1k
views
Longitudinal measures mixed model in lmer in R
I would like to build a mixed model using the lme4 package in R.
The study design is like this: We have measured the change in a variable over time in mice under different Diets. The mice under ...
1
vote
1
answer
42
views
R how best to model continuous bimodal survival data using lmer and glmmTMB that includes values of 0 and 1
I am attempting to model bimodal continuous coral survival data that includes values of 0 and 1 (0-100% survival).
I have attempted to use linear mixed effects models (lmer and glmmTMB) with a few ...
1
vote
1
answer
572
views
Growth curve analysis in R - time variable as a polynomial
I have narrowed down some specific questions and was advised that it's more appropriate to post them here than on stackoverflow
I'm building a growth curve model using lmer in R and I'm unsure about ...
2
votes
1
answer
158
views
predict() function fails for lmer in R when NAs present in dataset
The issue is not how to format/obtain data but how to run predictions for linear mixed effect model for given set os estimated fixed effects in case of NAs present in the data.
The predict() function ...
2
votes
2
answers
989
views
Fixed effect turns insignificant when including random effect - Multilevel
I have a data set from a diary study in which stress was assessed for 30 days. I want to build multilevel regressions (level 1: measurements, level 2: persons) to investigate the effect of different ...
1
vote
0
answers
32
views
Would it be okay to have a predictor that overlaps with the variable used as a random effect?
I will work with a predictor based on a Countries' Tightness index (numerical), so there’s one value for each country. I'll be collecting data in 50 countries, but I expect the number of participants ...
1
vote
1
answer
425
views
Help with modeling GRBDs experimental design analysis (Generalized randomized block design)
I am struggling with the formulation in lme of a generalized randomized block design (GRBD's) with subsampling.
The experiment consists of 2 treatments:
Genetic ...
0
votes
0
answers
51
views
P_values of 1 in LMM
Our team had words learning experiment and we decided to process the data with LMM
That the data structure, it's event-related potential(ERP) on different time intervals and
and then different ...
2
votes
1
answer
35
views
How can I compare one group to the mean of all other groups in a longitudinal mixed-effects regression?
I have a longitudinal mixed-effects regression comparing change in depression between two timepoints across 12 groups. I'd like to know if the control group is significantly less effective in reducing ...
4
votes
1
answer
133
views
Linear Mixed-effects Modelling for Mouse Tumor Growth Data
I tried going through the available materials online for this issue, but I did not manage to find many great resources. I would greatly appreciate any guidance or advice you could provide.
I have mice ...
1
vote
1
answer
55
views
Why do you always need to interact the covariates with the slope in mutlilevel models?
On a number of occassions, I have seen people remark that you should always interact your covariates with the with your slope when running multilevel models. That is, for example, you should not run ...
0
votes
1
answer
253
views
R nlme mixed model-how to run model by study subject
I'm trying to run a simple mixed model by subject id: y=week. Since it's repeated measures, I assume that I need to use mixed model even though I want to run the model by subject id?
In addition, ...
3
votes
1
answer
88
views
Interpretation lmer output with z-score standardized coefficients
I've been running lmer() (in the lme4 package) on my data using this formula:
...
8
votes
2
answers
6k
views
Modeling reaction time with glmer
According to Lo and Andrews, 2015 (https://doi.org/10.3389/fpsyg.2015.01171) raw Reaction Time (RT) should be analyzed with a GLMM, instead of transformed values with LMM or even ANOVA. They and ...
3
votes
1
answer
253
views
Should i exclude random effects from a model if the random effect itself has missing data?
I have found a number of questions relating to missing data in fixed effects and how packages like lme4 handle this in mixed models. For example, here. However, I ...
0
votes
0
answers
41
views
How do I correctly formulate the random effects with repeated measures in a paired design
Sorry if this is a cross-posting, but I haven't found the exact solution for my problem yet.
Let us assume I have an experiment with 20 households, with 2 people each (1 female + 1 male).
Over the ...
1
vote
2
answers
1k
views
Mathematical notation for glmer (GLMM)?
I'm looking for the mathematical notation equivalent of:
glmer(ret15i~AARC_Ret+(1|METRO)+ret02i)
I have a model; it is neither a HLM nor a GLM, but both. It is ...
4
votes
0
answers
138
views
Can we identify whether random effects are nested or crossed from a lme4 fit?
My colleagues and I are working on a suite of lmer post-estimation tools for a R package we are developing. One of the tools is an ICC function that would calculate ...