Next: rscanon() Up: Design Macros Help File Previous: randt()   Contents

reml()

Usage:
reml(Model,Randomvars[,restrict:F,nonhier:T,marg:T,maxiter:k,
    usemle:T,tolerance:x])



Keywords: analysis
reml(Model,Randomvars) performs a restricted maximum likelihood analysis
for the model given in CHARACTER scalar Model.  Randomvars
is a CHARACTER vector specifying the names of factors in the model which
are random.  Randomvars can also be REAL with integer elements
specifying the index of a factor in the model.  If there are no random
factors, Randomvars should be NULL.

The return value of reml() is a structure with the following components:
     theta:   estimates of the fixed effects
       phi:   estimates of the variance components
  thetavar:   variance matrix of the fixed effects
    phivar:   variance matrix of the variance components
     phidf:   equivalent degrees of freedom for the variance components
         L:   REML log likelihood

Any variates in the model must be fixed effects.

reml() assumes that if a factor first appears in an interaction, then
that factor is nested in the other terms of the interaction.  For
example, if the first appearance of factor c is in the term a.b.c, then
c is assumed nested in the a.b combinations.  This nesting is assumed in
the remainder of the model.  That is, continuing the example, if there
is a later term c.d, it will be interpreted as a.b.c.d even though
a.b.c.d is not specifically in the model.

reml() works for both balanced and unbalanced data.

reml(Model,Randomvars,restrict:F) performs the REML analysis assuming
no marginal restrictions on the random effects in the model.

reml(Model,Randomvars,nonhier:T) performs the REML analysis for an
analysis of variance that does not enforce the usual MacAnova hierarchy
assumptions.

That is, for example, model "y=a+b+c+a.b.c" does not imply
that the two-way interaction degrees of freedom are part of the "a.b.c"
term.  You cannot use anova() to compute such an analysis although it
can be done (if you know how) using swp().

reml(Model,Randomvars,usemle:T) performs a maximum likelihood analysis
instead of the REML analysis.

reml(Model,Randomvars,tolerance:value) uses value as a tolerance for
determining singularity and convergence (default is 1e-10).

reml(Model,Randomvars,maxiter:value) uses value as the maximum number of
iterations in the fitting process (default is 60).

See also mixed().


Gary Oehlert 2003-01-15