Skip to main content
Filter by
Sorted by
Tagged with
Advice
0 votes
1 replies
30 views

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 ...
Lene's user avatar
  • 33
3 votes
1 answer
90 views

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), ...
lordseal92's user avatar
0 votes
1 answer
74 views

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 ...
lyh970817's user avatar
1 vote
1 answer
260 views

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 ...
Jasper McCutcheon's user avatar
1 vote
0 answers
222 views

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) ...
Jasper McCutcheon's user avatar
2 votes
1 answer
295 views

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 ...
Tess H's user avatar
  • 79
2 votes
0 answers
521 views

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 (...
Annemarie's user avatar
  • 609
1 vote
1 answer
177 views

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 ...
sunny's user avatar
  • 17
0 votes
0 answers
51 views

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 ...
Gaby Heuchan's user avatar
1 vote
1 answer
259 views

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 ...
Liv's user avatar
  • 13
1 vote
0 answers
298 views

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 ...
Adrianna Elihu's user avatar
0 votes
0 answers
73 views

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 ...
Peter Kortenkamp's user avatar
0 votes
0 answers
754 views

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 ...
John M's user avatar
  • 1
0 votes
0 answers
44 views

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, ...
João Ferreira's user avatar
0 votes
1 answer
745 views

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 ...
aemmel's user avatar
  • 3
2 votes
2 answers
431 views

I am trying to reproduce with R the results from Intercepts- and Slopes-as Outcomes model from Hierarchical Linear Models by Raudenbush and Bryk, which deals with High School and Beyond dataset. Model ...
efiguero's user avatar
0 votes
1 answer
71 views

I'm trying to use the BugsNet package for NMA with contrast date. However, when performing the random effects model operation, the message above appears. I'm using the code below: library(BUGSnet) ...
RENATO LUÍS PESSOA's user avatar
3 votes
1 answer
1k views

I have a small data where there are 3 groups (A,B,C) and 5 participants from each group. All of those participants are measured 6 times on each of 7 different exams, so each participant get 6*7=42 ...
ksing's user avatar
  • 39
0 votes
0 answers
48 views

This is a continuation of my previous question listed here and works off of the lme4 tutorial for sleepstudy here. My 1st question is how can I use ggplot to graph a regression with random effects ...
JamesR's user avatar
  • 83
0 votes
1 answer
196 views

I am encountering difficulties while attempting to display the incidence rates per 100,000 as my effect size variable on a forest plot. The logged-transformed rates are being displayed correctly, ...
Abeer Sheikhhasan's user avatar
0 votes
0 answers
106 views

I need to fit a time series mixed model in nmle. I found that nlme allows to specify the heterogeneous structure of the variance. My response variable is yield, which is dependent on fixed factors: ...
Karen's user avatar
  • 1
0 votes
0 answers
95 views

I am trying to do a meta-analysis with a random effects model. The data includes: study, Odds Ratio (OR), and 95% confidence interval. For the meta-analysis, some categories were made consisting from ...
Noa's user avatar
  • 21
0 votes
1 answer
61 views

So We are triying to fit a glmm to my_data. my_data Figure Figure resume the descriptive statistic of my_data. D0.Richness is unbalanced (n=sample size for each Group1 level) as we can see in figure. ...
Peter.JS's user avatar
0 votes
1 answer
87 views

I'm performing a huge chunk of random-effects meta-analysis in R using the meta package and I am trying to export my results. However, I'm encountering a discrepancy in the pooled effect sizes per ...
user115916's user avatar
2 votes
1 answer
101 views

i have a question about mixed-effect in Pymer4 (same of lme4 but in python). My model is fitted under machine-learning to get the predicted values (Observed_values = predicted_values + total_residuals)...
Fayçal CHAIBEDDRA-TANI's user avatar
3 votes
1 answer
209 views

I am using the {GLMMadaptive} package to fit a mixed effect random slope model. And I need to extract the standard error of variance components from the output of GLMMadaptive::mixed_model(). And ...
Shafee's user avatar
  • 20.9k
2 votes
1 answer
307 views

I am attempting to calculate pseudo R squared's for a multilevel mixed-effect meta-regression that includes random slopes in the metafor package (i.e., rma.mv() object) using a similar approach to the ...
zr2015's user avatar
  • 33
0 votes
1 answer
78 views

I believe the same syntax is used with the lme4 package as rstanarm, but I'm having trouble figuring out exactly what the differences are between the different options when fitting a grouped random ...
colebrookson's user avatar
1 vote
1 answer
2k views

I have run several mixed models in lme4 with some main effects, a few interaction terms, and two random effects (animalID and year). My model looks like this: model <- lmer(response ~ ns(area_scale,...
madip's user avatar
  • 15
0 votes
1 answer
79 views

I have a longitudinal dataset for plant growth recorded in different seasons. I fitted the data to growth models with/without seasonal effect using nlme function from nlme package. To see the seasonal ...
TKH_9's user avatar
  • 117
4 votes
0 answers
108 views

I have a longitudinal dataset for plant growth that includes repeated measurements in different seasons. I am trying to estimate the parameters for a growth equation using this dataset. The growth ...
TKH_9's user avatar
  • 117
0 votes
1 answer
175 views

I have a longitudinal dataset for plant growth, where each row represents an individual plant's measurements over multiple seasons. The variables in the dataset include "id" (individual ...
TKH_9's user avatar
  • 117
0 votes
1 answer
56 views

I am learning to fit a tree taper mixed model using R. So I would like to know how can I add random effects in the model? Let's say we fit the model using variable-exponent taper funtion of Kozak (...
Thanapol CHOOCHUEN's user avatar
2 votes
1 answer
285 views

I am trying to fit a mixed model with random effects: lmer model to the dataset df based on this example here. However, I run into an error that says invalid "times" argument. Any ...
RPlotter's user avatar
  • 109
1 vote
1 answer
726 views

I'm having trouble translating my sample design into the correct mgcv package syntax for random effects. Here is the set-up: we trawl for fish, once per "collection" site, at the same 12 ...
Nate's user avatar
  • 489
0 votes
1 answer
713 views

I have a data frame in R - my code is as follows: library(lme4) library(lmerTest) library(multcomp) #Create DF df <- data.frame( col1 = rep(1:3, each = 3), col2 = rep(c("A", "B&...
Yuval Neumann's user avatar
0 votes
1 answer
887 views

I'm trying to understand what actually happens when using exclude to exclude subject-random slope terms from the prediction function mgcv::predict.gam(). I'm finding that regardless of whether I ...
midily's user avatar
  • 21
0 votes
0 answers
235 views

I would like to fit a mixed model in R using the library nlme. I have three levels: election year, district, and candidates (unfortunately I cannot share the data). Districts are nested in election ...
roalt102's user avatar
0 votes
1 answer
412 views

From my layman understanding of frequentist hierarchical models, there is some penalty mechanism built into the likelihood function, that prevents the random effects from overfitting to the data and ...
Will T-E's user avatar
  • 637
0 votes
1 answer
447 views

I am trying to re-create some SAS mixed model analyses using the lme function of R. The following SAS code: proc mixed data = df noclprint covtest; class patid visno; model va = cst va0 cst0 / ...
Neal Oden's user avatar
-1 votes
1 answer
144 views

I am analyzing a dataset with multilevel modelling in R using the lme4 package. I conducted a study where The influence of participants and learning materials were counterbalanced. Participants went ...
user8460166's user avatar
1 vote
0 answers
265 views

I would like to make a multinomial model with random effects, but I don't know how. The model would look like this: native_driftertype ~treat+(1|replica)+(1|compartment/originhive), with ...
user avatar
0 votes
1 answer
176 views

I have a nested data set specifying cells (no, 240 values) within experimenters (experimenter_1_2, 2 values), as well as treatment status for three different treatments (cis_0_1, 2 values; rt_0_1, 2 ...
HNSKD's user avatar
  • 1,654
3 votes
0 answers
561 views

I want to estimate a Tobit model with random effects and afterwards use the model for prediction. Estimation is possible with the censReg package, however it does not provide a predict function. I ...
Nerd's user avatar
  • 91
1 vote
1 answer
558 views

I'm trying to run glmmLasso on some data with the subject IDs established as the groups for random effects. This is seen in several posted examples of glmmLasso and the example soccer data set ...
trytryagain404's user avatar
1 vote
1 answer
269 views

I have a linear mixed effects model and I am trying to do variable selection. The model is testing the level of forest degradation in 1000 sampled points. Most points have no degradation, and so the ...
Matt Marcus's user avatar
0 votes
1 answer
423 views

I'm trying to fit a multilevel (random effects) ordered logit model using the ordinal package, but I keep running into this error: Error in region:country1 : NA/NaN argument Here's my simplified ...
Reuben Long's user avatar
0 votes
1 answer
29 views

I am creating randomly fading squares on the image. They end up one by one partially revealing the image. This function was meant to hide random squares one by one but it is hiding them abnormally. ...
Khwaeesh Patel's user avatar
1 vote
1 answer
1k views

I have a mixed model where I'm trying to find the significance of my random effect. The model is a mixed model with zero-inflated beta distribution which I built using the R package glmmTMB, with the ...
Cam's user avatar
  • 453
0 votes
0 answers
91 views

I'm trying to produce partial regressions based on an rma object: tmc<-rma(yi, vi, mods = ~ temp_annual_range+max_temp+min_temp+Wildfire, method="ML", data=formsc) Based on this, I want ...
julia_k's user avatar

1
2 3 4 5