New answers tagged

3 votes
Accepted

How to code for a mulitgroup analysis concerning two catagorical variables

One option could be to combine the two grouping variables (sex, country) into a single grouping variable, for example, as follows: Category 1: US males Category 2: US females Category 3: Canadian ...
Christian Geiser's user avatar
0 votes

Random effect variance with or without fixed-effects intercept

I agree with @Roland's comment. What values does SAM_Aro take? Keep in mind that the mean of both sets of random intercepts (participant and video) is, by ...
Doctor Milt's user avatar
  • 2,682
6 votes
Accepted

Multilevel model with random subset of conditions per participant

Yes, that should work fine provided you have enough participants. You could convince yourself (without math) by simulating some data from such an experimental design and showing that you can recover ...
Ben Bolker's user avatar
  • 43.1k
0 votes

Why do I get very bad fit indices for a moderation? (including a negative TLI!) / Multilevel Model

I would need to know more about your model and data to recommend anything besides looking at modification indices (i.e., what @Erik Ruzek and @michael_zyphur suggest you do). Though my guess is that a ...
Preston Botter's user avatar
5 votes

How to add interaction and covariates to linear mixed effects model in R

Fixed/Random Variable Inputs There's nothing stopping you from adding any number of variables that were measured at baseline. If this measure was also repeated, then you would need to code that into ...
Shawn Hemelstrand's user avatar
0 votes

Mediation package error message with group level mediator (bug?)

On line 721 of mediate.R, there is code that extracts the ids from the mediation model. In this instance, of a lm mediation model and a ...
swihart's user avatar
  • 135
4 votes

Advice on optimal random-effects structure for not fully crossed repeated-measures design?

The question of how to model this data is an important one, but before doing so, I want to show how the structure of the data can provide clues about the true design your study implies. Note that I ...
Erik Ruzek's user avatar
  • 4,590
1 vote

Better understanding of "within" and "between" in multilevel models

In addition to @Christian Geiser's excellent answer, it can be helpful to write out the model in the two-stage form, which shows equations for the within and between parts of the model. Level 1 (...
Erik Ruzek's user avatar
  • 4,590
1 vote

Better understanding of "within" and "between" in multilevel models

What you have is often referred to as a "random coefficient regression." See, e.g., the reference below. The intercept and slope of the level 1 (within-level) regression are called "...
Christian Geiser's user avatar

Top 50 recent answers are included