[R-sig-ME] Interpreting variances for random effects

Chen, Gang (NIH/NIMH) [C] gangchen at mail.nih.gov
Mon Jun 12 19:23:04 CEST 2017


I’m trying to run a meta mixed-effects model with the R package ‘blme’, but I have trouble understanding the variances for the random effects in the output. Let me demonstrate my questions with the following dataset:

dat <- read.table(text='
   Subj   ses          Beta         vi
s20447  T1  0.0918712467 0.06086247
s20973  T1  0.0275931843 0.08578725
s21163  T1  0.0159543231 0.01198331
s21209  T1  0.2722044587 0.05239982
s21590  T1 -0.2647554576 0.04842246
s21606  T1 -0.0915029198 0.02063762
s21728  T1 -0.1098448336 0.08973302
s22177  T1  0.0070983637 0.01515363
s22380  T1  0.0660349280 0.10569247
s22437  T1 -0.0825878531 0.12504976
s22481  T1 -0.3160937428 0.05636208
s22542  T1 -0.3765429556 0.05385343
s22660  T1  0.1904570013 0.01808839
s22687  T1 -0.3090784848 0.03609267
s22717  T1 -0.5519740582 0.08041095
s22774  T1  0.0318013728 0.01584950
s22819  T1 -0.0250370707 0.01560509
s22828  T1  0.1122434586 0.07531304
s22834  T1 -0.0590136759 0.04191800
s22861  T1 -0.0165097713 0.02500125
s22881  T1  0.0004725010 0.01726706
s22959  T1  0.3902115524 0.04177956
s23107  T1  0.0069795060 0.01592698
s23154  T1  0.0790746883 0.09956493
s23193  T1  0.5274482369 0.02718767
s20447  T2 -0.0148665439 0.03070799
s20973  T2  0.1085031107 0.07011064
s21163  T2 -0.0075897672 0.00944575
s21209  T2 -0.4167304039 0.02853584
s21590  T2  0.0006625475 0.04409404
s21606  T2  0.1917003244 0.02087413
s21728  T2 -0.1185217202 0.05121711
s22177  T2 -0.0446757786 0.01802203
s22380  T2 -0.3420846760 0.08059885
s22437  T2 -0.0735468194 0.19387151
s22481  T2  0.1410380155 0.02487867
s22542  T2 -0.1882588267 0.04918930
s22660  T2  0.0079449303 0.03648700
s22687  T2  0.1746368855 0.03746678
s22717  T2 -0.2987288833 0.05659567
s22774  T2 -0.1838540286 0.04245462
s22819  T2 -0.2798163295 0.01841418
s22828  T2 -0.5080602765 0.14406914
s22834  T2 -0.1628637910 0.02220246
s22861  T2  0.2190277874 0.03104834
s22881  T2 -0.1975046396 0.01770617
s22959  T2 -0.1411849707 0.03163359
s23107  T2 -0.0360546894 0.01652099
s23154  T2  0.5842899084 0.08301191
s23193  T2 -0.2372864336 0.02257293', header=T)

require('blme')
summary(blmer(Beta~1+ses+(1|Subj), data=dat, resid.prior = point, cov.prior=gamma(shape = 2, rate = 0.5, posterior.scale = 'sd'), weights=1/vi))

…
Random effects:
Groups   Name        Variance Std.Dev.
Subj     (Intercept) 0.02706  0.1645
 Residual             1.00000  1.0000
Number of obs: 50, groups:  Subj, 25
…
convergence code: 0
Model failed to converge with max|grad| = 6.50544 (tol = 0.002, component 1)

Warning message:
In get("checkConv", lme4Namespace)(attr(opt, "derivs"), opt$par,  :
  Model failed to converge with max|grad| = 6.50544 (tol = 0.002, component 1)

Here are my questions:


  1.  I’ve been using the variance prior of “gamma(shape = 2, rate = 0.5, posterior.scale = 'sd')” as a weakly informative prior, which usually works fine. However, this is the first time I have the convergence problem. Could you offer some suggestion as to how to deal with the convergence issue like this? I tried to change the shape parameter from 2 to 20 , which seems to get rid of the convergence problem, but I don’t feel comfortable with such a large and strong shape parameter value. Maybe the convergence failure is OK per Dr. Bolker’s suggestion (http://bbolker.github.io/mixedmodels-misc/notes/bglmer_cmp.html) in another thread?
  2.  The variance for “Subj” is what I’m interested here. It seems the variance for “Residual” is always 1 when the option “weights” is used. How to interpret this? Does it mean that the variance for “Subj” should be interpreted as being scaled somehow?

Thanks,
Gang



	[[alternative HTML version deleted]]



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