# [R-sig-ME] Advice on Mixed Models

Rose Rosei roserosei2030 at gmail.com
Wed Mar 8 20:01:48 CET 2017

```Dear Advisors

Would you please advise me. I would like to fit my model, but I struggled
to do it

A= Applicant = 10 persons
S= Stream ( four levels, 1, 2)
D= Day   (1,2)
S1= Session ( 1,2)
Q = Qestion ( 1-to 8)
Applicants are crossed in Questions, but Applicants nested in Stream,
nested in Day, nested in session (S1). All variables are a a random factor

I want to calculate SD for A, S, D, S1 and Q, and their interaction
.score=dependent variable

I have used the following codes, but it seems they are wrong.

lmer(score~ (1|A)+(1|S)+(1+D)+(1|S1)+(1|Q)+(1|A/S)+1|S/D)+(1|D/S1)+(1|S1/Q),
R)

Linear mixed model fit by REML ['lmerMod']
Formula: score ~ (1 | A) + (1 | S) + (1 + D) + (1 | S1) + (1 | Q) + (1 |
A/S) + (1 | S/D) + (1 | D/S1) + (1 | S1/Q)
Data: R
REML criterion at convergence: 192.4591
Random effects:
Groups   Name        Std.Dev.
Q.S1     (Intercept) 0.000e+00
A        (Intercept) 2.383e-01
S.A      (Intercept) 7.692e-01
A.1      (Intercept) 8.399e-01
Q        (Intercept) 0.000e+00
S1.D     (Intercept) 1.386e-08
D.S      (Intercept) 0.000e+00
S1       (Intercept) 0.000e+00
D        (Intercept) 9.498e-01
S        (Intercept) 0.000e+00
S1.1     (Intercept) 0.000e+00
S.1      (Intercept) 0.000e+00
Residual             6.722e-01
Number of obs: 80, groups:
Q:S1, 16; A, 10; S:A, 10; Q, 8; S1:D, 4; D:S, 4; S1, 2; D, 2; S, 2
Fixed Effects:
(Intercept)            D
1.61458     -0.07292
convergence code 0; 2 optimizer warnings; 0 lme4 warnings

Very much appreciated for your help.
looking forward to hearing from you.
Rose

[[alternative HTML version deleted]]

```