Wolfram Language
Paclet Repository
Community-contributed installable additions to the Wolfram Language
Primary Navigation
Categories
Cloud & Deployment
Core Language & Structure
Data Manipulation & Analysis
Engineering Data & Computation
External Interfaces & Connections
Financial Data & Computation
Geographic Data & Computation
Geometry
Graphs & Networks
Higher Mathematical Computation
Images
Knowledge Representation & Natural Language
Machine Learning
Notebook Documents & Presentation
Scientific and Medical Data & Computation
Social, Cultural & Linguistic Data
Strings & Text
Symbolic & Numeric Computation
System Operation & Setup
Time-Related Computation
User Interface Construction
Visualization & Graphics
Random Paclet
Alphabetical List
Using Paclets
Create a Paclet
Get Started
Download Definition Notebook
Learn More about
Wolfram Language
MMAMixedEffects
Guides
MMA MixedEffects
Symbols
GeneralizedMixedEffectsModelFit
MixedEffectsFamily
MixedEffectsModelFit
MixedEffectsModel
NestedGrouping
NonlinearMixedEffectsModelFit
MarcoThiel`MMAMixedEffects`
N
e
s
t
e
d
G
r
o
u
p
i
n
g
N
e
s
t
e
d
G
r
o
u
p
i
n
g
[
g
1
,
g
2
,
.
.
.
]
f
o
r
m
s
a
n
o
r
d
e
r
e
d
c
o
m
p
o
s
i
t
e
l
e
v
e
l
f
r
o
m
t
w
o
o
r
m
o
r
e
g
r
o
u
p
i
n
g
v
a
r
i
a
b
l
e
s
.
D
e
t
a
i
l
s
a
n
d
O
p
t
i
o
n
s
▪
constructs an explicit composite grouping level.
▪
NestedGrouping is inert until row values are substituted.
▪
To model classrooms nested within schools, include a school random structure and a NestedGrouping[school,classroom] structure.
▪
Argument order is significant and every constituent value must be supplied during prediction.
▪
NestedGrouping has no options.
Examples
(
3
)
Basic Examples
(
1
)
Represent subjects nested within sites explicitly:
I
n
[
1
]
:
=
N
e
s
t
e
d
G
r
o
u
p
i
n
g
[
s
i
t
e
,
s
u
b
j
e
c
t
]
O
u
t
[
1
]
=
N
e
s
t
e
d
G
r
o
u
p
i
n
g
[
S
i
t
e
1
,
S
u
b
j
e
c
t
A
]
Visualize the hierarchy represented by the composite keys:
I
n
[
1
]
:
=
O
u
t
[
1
]
=
S
c
o
p
e
(
1
)
P
r
o
p
e
r
t
i
e
s
&
R
e
l
a
t
i
o
n
s
(
1
)
S
e
e
A
l
s
o
M
i
x
e
d
E
f
f
e
c
t
s
M
o
d
e
l
F
i
t
▪
G
e
n
e
r
a
l
i
z
e
d
M
i
x
e
d
E
f
f
e
c
t
s
M
o
d
e
l
F
i
t
▪
N
o
n
l
i
n
e
a
r
M
i
x
e
d
E
f
f
e
c
t
s
M
o
d
e
l
F
i
t
R
e
l
a
t
e
d
G
u
i
d
e
s
▪
M
M
A
M
i
x
e
d
E
f
f
e
c
t
s
R
e
l
a
t
e
d
L
i
n
k
s
▪
M
i
x
e
d
E
f
f
e
c
t
s
M
o
d
e
l
F
i
t
▪
N
o
n
l
i
n
e
a
r
M
i
x
e
d
E
f
f
e
c
t
s
M
o
d
e
l
F
i
t
"
"