242 questions
Advice
0 votes
1 replies
32 views
Check assumptions of mixed effects cox model
I am running a mixed effects cox model using coxme in R, and I cannot find any information on how to check model assumptions for this type of model. I have seen the older chats, which have recommended ...
3 votes
1 answer
93 views
Using sjPlot::plot_model to generate plot of lmer model with log-transformed dependent variable
I've got a lmer model that looks similar to the following example: library(lme4) df<-data.frame(var_1=c(1.1,2.2,2.1,4.4,4.4,5.6,4.4,2.6,3.3,3.3,3.9,3.8,1.1,1.3,1.4,1.1,1.8,2.1), ...
0 votes
1 answer
74 views
Random Effects v.s. Random Design Matrix
It is commonly explained that a random effect is used when the values of the variable associated with the random effect are drawn from a population, such as schools in the sample out of schools in the ...
1 vote
1 answer
266 views
How to format a random effect (i.e., + 0 vs. + 1) in my glmmTMB models
I am working on creating GLMMs to determine the effect of in-air noise on harbor seals. I have a couple other fixed predictor variables (current velocity and time) and some random effects. As I am ...
1 vote
0 answers
223 views
ar1() or ou() for my glmmTMB models in RStudio?
I am working on creating GLMMs to determine the effect of in-air noise on harbor seals (specifically the number present). I have a couple other fixed predictor variables (current velocity and time) ...
2 votes
1 answer
301 views
How can I extract and report the random slopes and confidence from a glmer in R?
I would like to report the random slopes from a binomial lme4::glmer model along with their confidence or deviations. I am adding the fixed effect to each random effect to obtain slopes, but how do I ...
2 votes
0 answers
522 views
Plotting brms random effects with tidybayes
Tidybayes can make great-looking plots for the output of Bayesian models, but it's not clear (as far as I can see) how to do this for different types of models. So for fixed effects, we can do this (...
1 vote
1 answer
177 views
How to test more than one random slope in R for significance?
I set up a multilevel model in R with the lme4-package to test different effects on social participation in primary school classes. Now I assume that the effects of academic performance (sp) and ...
0 votes
0 answers
51 views
Is it normal that lme + random gives lower estimates than gls?
I was using a gls to model BMI trajectories based on intake of a nutrient, but realised I needed to switch to lme de to the multi-level clustering of my sample (twinID within famID). The code for my ...
1 vote
1 answer
259 views
How to specify year for nested random effect?
I am quite new to R and is setting up a mixed effect model with lmer. I have a large dataset and want to include 3 random effects that are nested. I have data from 2 years, 2021 and 2022, and there ...
1 vote
0 answers
298 views
glmmTMB and nested random effects
I'm fairly new with stats and using glmmTMB and glmer, so bare with my explanation. I'm analyzing data that is looking to see how different socioeconomic variables interact with each other and predict ...
0 votes
0 answers
74 views
Why would repeated measures random effects model values from polr() (in MASS package in R) be identical for all data points?
I have survey data involving two categorical IVs (Prompt_Condition and Response_Condition) of three levels each and one ordinal DV (value, a Likert-type ranking 1-7). There are 31 subjects who rated ...
0 votes
0 answers
758 views
how do I fix this glmer error in r: PIRLS loop resulted in NaN value
I am trying to run a random effects generalized linear model specifying the family as binomial and a log link to estimate risk ratio (RR) and 95% confidence intervals (CIs). When I run it, I keep ...
0 votes
0 answers
45 views
I need help in estimates lme models
I'm analyzing two models of class LME for longitudinal data (observations in two times), but this message appears Error in lme.formula(y ~ x, random = ~1 | id, data = data_long) : nlminb problem, ...
0 votes
1 answer
750 views
Repeated measures in random effect lmer
I am looking at data from repeated experiments with 3 participants (hawks). We recorded the number of times we did the experiment with them (about 50x each) so that we could account for their learning ...