[R-sig-ME] next question about random effects (and where to post)

Don Cohen don-|me4 @end|ng |rom |@|@@c@3-|nc@com
Thu Oct 29 02:20:29 CET 2020


Ben Bolker writes:

 >   This is one of the advantages of forums like StackOverflow or 
 > CrossValidated that (1) are much easier to search for old questions; (2) 
 > allow people to offer 'brownie points' for solutions to interesting 
 > questions.  (I think a sufficient interval has gone by that it would be 
 > reasonable to cross-post it to CrossValidated ...)

I've now posted a few things to CrossValidated and seen no responses:

https://stats.stackexchange.com/questions/242821/how-will-random-effects-with-only-1-observation-affect-a-generalized-linear-mixe/493597

https://stats.stackexchange.com/questions/493601/random-effect-with-one-observation-per-group-improves-aic-drastically-explain

So that's one reason to send the next one back here.
This is related to the first link above, but it may actually
be specific to glmmTMB.  In fact it didn't work in lmer, I 
gather precisely because it has as many groups as obervations.

Here I have a random effect with one group per observation,
which I claimed made sense in cases like the second link above,
but not in THIS case.  And yet I get no complaints, and a 
separate variance for the residual and the group.
I don't understand how these can be separated.  
Wouldn't any combination of the two with the same sum of 
variances give the same loglik ?  Or perhaps this solution
is being returned since it's as good as any other, even though
others are equally good?  (But without warning?)


> md2 <- glmmTMB( Y ~ (1|Id), data = d2 )
> summary(md2)
 Family: gaussian  ( identity )
Formula:          Y ~ (1 | Id)
Data: d2

     AIC      BIC   logLik deviance df.resid 
    18.4     16.5     -6.2     12.4        1 

Random effects:

Conditional model:
 Groups   Name        Variance Std.Dev.
 Id       (Intercept) 0.4248   0.6518  
 Residual             0.8606   0.9277  
Number of obs: 4, groups:  Id, 4

Dispersion estimate for gaussian family (sigma^2): 0.861 

Conditional model:
            Estimate Std. Error z value Pr(>|z|)    
(Intercept)  10.0478     0.5669   17.73   <2e-16 ***



More information about the R-sig-mixed-models mailing list