The GLIMMIX Procedure

RANDOM Statement

  • RANDOM random-effects </ options>;

Using notation from Notation for the Generalized Linear Mixed Model, the RANDOM statement defines the bold upper Z matrix of the mixed model, the random effects in the bold-italic gamma vector, the structure of bold upper G, and the structure of bold upper R.

The bold upper Z matrix is constructed exactly like the bold upper X matrix for the fixed effects, and the bold upper G matrix is constructed to correspond to the effects constituting bold upper Z. The structures of bold upper G and bold upper R are defined by using the TYPE= option described on . The random effects can be classification or continuous effects, and multiple RANDOM statements are possible.

Some reserved keywords have special significance in the random-effects list. You can specify INTERCEPT (or INT) as a random effect to indicate the intercept. PROC GLIMMIX does not include the intercept in the RANDOM statement by default as it does in the MODEL statement. You can specify the _RESIDUAL_ keyword (or RESID, RESIDUAL, _RESID_) before the option slash (/) to indicate a residual-type (R-side) random component that defines the bold upper R matrix. Basically, the _RESIDUAL_ keyword takes the place of the random-effect if you want to specify R-side variances and covariance structures. These keywords take precedence over variables in the data set with the same name. If your data or the covariance structure requires that an effect is specified, you can use the RESIDUAL option to instruct the GLIMMIX procedure to model the R-side variances and covariances.

In order to add an overdispersion component to the variance function, simply specify a single residual random component. For example, the following statements fit a polynomial Poisson regression model with overdispersion. The variance function a left-parenthesis mu right-parenthesis equals mu is replaced by phi a left-parenthesis mu right-parenthesis:

proc glimmix;
   model count = x x*x / dist=poisson;
   random _residual_;
run;

Table 19 summarizes the options available in the RANDOM statement. All options are subsequently discussed in alphabetical order.

Table 19: RANDOM Statement Options

Option Description
Construction of Covariance Structure
GCOORD= Determines coordinate association for G-side spatial structures with repeat levels
GROUP= Varies covariance parameters by groups
LDATA= Specifies a data set with coefficient matrices for TYPE= LIN
NOFULLZ Eliminates columns in bold upper Z corresponding to missing values
RESIDUAL Designates a covariance structure as R-side
SUBJECT= Identifies the subjects in the model
TYPE= Specifies the covariance structure
WEIGHT= Specifies the weights for the subjects
Mixed Model Smoothing
KNOTINFO Displays spline knots
KNOTMAX= Specifies the upper limit for knot construction
KNOTMETHOD Specifies the method for constructing knots for radial smoother and penalized B-splines
KNOTMIN= Specifies the lower limit for knot construction
Statistical Output
ALPHA=alpha Determines the confidence level (1 minus alpha)
CL Requests confidence limits for predictors of random effects
G Displays the estimated bold upper G matrix
GC Displays the Cholesky root (lower) of the estimated bold upper G matrix
GCI Displays the inverse Cholesky root (lower) of the estimated bold upper G matrix
GCORR Displays the correlation matrix that corresponds to the estimated bold upper G matrix
GI Displays the inverse of the estimated bold upper G matrix
SOLUTION Displays solutions ModifyingAbove bold-italic gamma With caret of the G-side random effects
V Displays blocks of the estimated bold upper V matrix
VC Displays the lower-triangular Cholesky root of blocks of the estimated bold upper V matrix
VCI Displays the inverse Cholesky root of blocks of the estimated bold upper V matrix
VCORR Displays the correlation matrix corresponding to blocks of the estimated bold upper V matrix
VI Displays the inverse of the blocks of the estimated bold upper V matrix


You can specify the following options in the RANDOM statement after a slash (/).

ALPHA=number

requests that a t-type confidence interval with confidence level 1 – number be constructed for the predictors of G-side random effects in this statement. The value of number must be between 0 and 1; the default is 0.05. Specifying the ALPHA= option implies the CL option.

CL

requests that t-type confidence limits be constructed for each of the predictors of G-side random effects in this statement. The confidence level is 0.95 by default; this can be changed with the ALPHA= option. The CL option implies the SOLUTION option.

G

requests that the estimated bold upper G matrix be displayed for G-side random effects associated with this RANDOM statement. PROC GLIMMIX displays blanks for values that are 0.

GC

displays the lower-triangular Cholesky root of the estimated bold upper G matrix for G-side random effects.

GCI

displays the inverse Cholesky root of the estimated bold upper G matrix for G-side random effects.

GCOORD=LAST | FIRST | MEAN

determines how the GLIMMIX procedure associates coordinates for TYPE=SP() covariance structures with effect levels for G-side random effects. In these covariance structures, you specify one or more variables that identify the coordinates of a data point. The levels of classification variables, on the other hand, can occur multiple times for a particular subject. For example, in the following statements the same level of A can occur multiple times, and the associated values of x might be different:

proc glimmix;
   class A B;
   model y = B;
   random A / type=sp(pow)(x);
run;

The GCOORD=LAST option determines the coordinates for a level of the random effect from the last observation associated with the level. Similarly, the GCOORD=FIRST and GCOORD=MEAN options determine the coordinate from the first observation and from the average of the observations. Observations not used in the analysis are not considered in determining the first, last, or average coordinate. The default is GCOORD=LAST.

GCORR

displays the correlation matrix that corresponds to the estimated bold upper G matrix for G-side random effects.

GI

displays the inverse of the estimated bold upper G matrix for G-side random effects.

GROUP=effect
GRP=effect

identifies groups by which to vary the covariance parameters. Each new level of the grouping effect produces a new set of covariance parameters. Continuous variables and computed variables are permitted as group effects. PROC GLIMMIX does not sort by the values of the continuous variable; rather, it considers the data to be from a new group whenever the value of the continuous variable changes from the previous observation. Using a continuous variable decreases execution time for models with a large number of groups and also prevents the production of a large "Class Levels Information" table.

Specifying a GROUP effect can greatly increase the number of estimated covariance parameters, which can adversely affect the optimization process.

KNOTINFO

displays the number and coordinates of the knots as determined by the KNOTMETHOD= option.

KNOTMAX=number-list

provides upper limits for the values of random effects used in the construction of knots for TYPE=RSMOOTH. The items in number-list correspond to the random effects of the radial smooth. If the KNOTMAX= option is not specified, or if the value associated with a particular random effect is set to missing, the maximum is based on the values in the data set for KNOTMETHOD=EQUAL or KNOTMETHOD=KDTREE, and is based on the values in the knot data set for KNOTMETHOD=DATA.

KNOTMETHOD=KDTREE<(tree-options)>
KNOTMETHOD=EQUAL<(number-list)>
KNOTMETHOD=DATA(SAS-data-set)

determines the method of constructing knots for the radial smoother fit with the TYPE=RSMOOTH covariance structure and the TYPE=PSPLINE covariance structure.

Unless you select the TYPE=RSMOOTH or TYPE=PSPLINE covariance structure, the KNOTMETHOD= option has no effect. The default for TYPE=RSMOOTH is KNOTMETHOD=KDTREE. For TYPE=PSPLINE, only equally spaced knots are used and you can use the optional numberlist argument of KNOTMETHOD=EQUAL to determine the number of interior knots for TYPE=PSPLINE.

Knot Construction for TYPE=RSMOOTH

PROC GLIMMIX fits a low-rank smoother, meaning that the number of knots is considerably less than the number of observations. By default, PROC GLIMMIX determines the knot locations based on the vertices of a k-d tree (Friedman, Bentley, and Finkel 1977; Cleveland and Grosse 1991). The k-d tree is a tree data structure that is useful for efficiently determining the m nearest neighbors of a point. The k-d tree also can be used to obtain a grid of points that adapts to the configuration of the data. The process starts with a hypercube that encloses the values of the random effects. The space is then partitioned recursively by splitting cells at the median of the data in the cell for the random effect. The procedure is repeated for all cells that contain more than a specified number of points, b. The value b is called the bucket size.

The k-d tree is thus a division of the data into cells such that cells representing leaf nodes contain at most b values. You control the building of the k-d tree through the BUCKET= tree-option. You control the construction of knots from the cell coordinates of the tree with the other options as follows.

BUCKET=number

determines the bucket size b. A larger bucket size will result in fewer knots. For k-d trees in more than one dimension, the correspondence between bucket size and number of knots is difficult to determine. It depends on the data configuration and on other suboptions. In the multivariate case, you might need to try out different bucket sizes to obtain the desired number of knots. The default value of number is 4 for univariate trees (a single random effect) and left floor 0.1 n right floor in the multidimensional case.

KNOTTYPE=type

specifies whether the knots are based on vertices of the tree cells or the centroid. The two possible values of type are VERTEX and CENTER. The default is KNOTTYPE=VERTEX. For multidimensional smoothing, such as smoothing across irregularly shaped spatial domains, the KNOTTYPE=CENTER option is useful to move knot locations away from the bounding hypercube toward the convex hull.

NEAREST

specifies that knot coordinates are the coordinates of the nearest neighbor of either the centroid or vertex of the cell, as determined by the KNOTTYPE= suboption.

TREEINFO

displays details about the construction of the k-d tree, such as the cell splits and the split values.

See the section Knot Selection for a detailed example of how the specification of the bucket size translates into the construction of a k-d tree and the spline knots.

The KNOTMETHOD=EQUAL option enables you to define a regular grid of knots. By default, PROC GLIMMIX constructs 10 knots for one-dimensional smooths and 5 knots in each dimension for smoothing in higher dimensions. You can specify a different number of knots with the optional number-list. Missing values in the number-list are replaced with the default values. A minimum of two knots in each dimension is required. For example, the following statements use a rectangular grid of 35 knots, five knots for x1 combined with seven knots for x2:

proc glimmix;
   model y=;
   random x1 x2 / type=rsmooth knotmethod=equal(5 7);
run;

When you use the NOFIT option in the PROC GLIMMIX statement, the GLIMMIX procedure computes the knots but does not fit the model. This can be useful if you want to compare knot selections with different suboptions of KNOTMETHOD=KDTREE. Suppose you want to determine the number of knots based on a particular bucket size. The following statements compute and display the knots in a bivariate smooth, constructed from nearest neighbors of the vertices of a k-d tree with bucket size 10:

proc glimmix nofit;
   model y = Latitude Longitude;
   random Latitude Longitude / type=rsmooth
                   knotmethod=kdtree(knottype=vertex
                   nearest bucket=10) knotinfo;
run;

You can specify a data set that contains variables whose values give the knot coordinates with the KNOTMETHOD=DATA option. The data set must contain numeric variables with the same name as the radial smoothing random-effects. PROC GLIMMIX uses only the unique knot coordinates in the knot data set. This option is useful to provide knot coordinates different from those that can be produced from a k-d tree. For example, in spatial problems where the domain is irregularly shaped, you might want to determine knots by a space-filling algorithm. The following SAS statements invoke the OPTEX procedure to compute 45 knots that uniformly cover the convex hull of the data locations (see SAS/QC User's Guide for details about the OPTEX procedure).

proc optex coding=none;
   model latitude longitude / noint;
   generate n=45 criterion=u method=m_fedorov;
   output out=knotdata;
run;
proc glimmix;
   model y = Latitude Longitude;
   random Latitude Longitude / type=rsmooth
                   knotmethod=data(knotdata);
run;

Knot Construction for TYPE=PSPLINE

Only evenly spaced knots are supported when you fit penalized B-splines with the GLIMMIX procedure. For the TYPE=PSPLINE covariance structure, the number-list argument specifies the number m of interior knots, the default is m equals 10. Suppose that x Subscript left-parenthesis 1 right-parenthesis and x Subscript left-parenthesis n right-parenthesis denote the smallest and largest values, respectively. For a B-spline of degree d (De Boor 2001), the interior knots are supplemented with d exterior knots below x Subscript left-parenthesis 1 right-parenthesis and normal m normal a normal x StartSet 1 comma d EndSet exterior knots above x Subscript left-parenthesis n right-parenthesis. PROC GLIMMIX computes the location of these m plus d plus normal m normal a normal x StartSet 1 comma d EndSet knots as follows. Let delta Subscript x Baseline equals left-parenthesis x Subscript left-parenthesis n right-parenthesis Baseline minus x Subscript left-parenthesis 1 right-parenthesis Baseline right-parenthesis slash left-parenthesis m plus 1 right-parenthesis, then interior knots are placed at

x Subscript left-parenthesis 1 right-parenthesis Baseline plus j delta Subscript x Baseline comma j equals 1 comma ellipsis comma m

The exterior knots are also evenly spaced with step size delta Subscript x and start at x Subscript left-parenthesis 1 right-parenthesis Baseline plus-or-minus 100 times the machine epsilon. At least one interior knot is required.

KNOTMIN=number-list

provides lower limits for the values of random effects used in the construction of knots for TYPE=RSMOOTH. The items in number-list correspond to the random effects of the radial smooth. If the KNOTMIN= option is not specified, or if the value associated with a particular random effect is set to missing, the minimum is based on the values in the data set for KNOTMETHOD=EQUAL or KNOTMETHOD=KDTREE, and is based on the values in the knot data set for KNOTMETHOD=DATA.

LDATA=SAS-data-set

reads the coefficient matrices bold upper A 1 comma ellipsis comma bold upper A Subscript q Baseline for the TYPE=LIN(q) option. You can specify the LDATA= data set in a sparse or dense form. In the sparse form the data set must contain the numeric variables Parm, Row, Col, and Value. The Parm variable contains the indices i equals 1 comma ellipsis comma q of the bold upper A Subscript i matrices. The Row and Col variables identify the position within a matrix and the Value variable contains the matrix element. Values not specified for a particular row and column are set to zero. Missing values are allowed in the Value column of the LDATA= data set; these values are also replaced by zeros. The sparse form is particularly useful if the bold upper A matrices have only a few nonzero elements.

In the dense form the LDATA= data set contains the numeric variables Parm and Row (with the same function as above), in addition to the numeric variables Col1Colq. If you omit one or more of the Col1Colq variables from the data set, zeros are assumed for the respective rows and columns of the bold upper A matrix. Missing values for Col1Colq are ignored in the dense form.

The GLIMMIX procedure assumes that the matrices bold upper A 1 comma ellipsis comma bold upper A Subscript q Baseline are symmetric. In the sparse LDATA= form you do not need to specify off-diagonal elements in position left-parenthesis i comma j right-parenthesis and left-parenthesis j comma i right-parenthesis. One of them is sufficient. Row-column indices are converted in both storage forms into positions in lower triangular storage. If you specify multiple values in row left-parenthesis max left-brace i comma j right-brace and column min left-brace i comma j right-brace right-parenthesis of a particular matrix, only the last value is used. For example, assume you are specifying elements of a 4 times 4 matrix. The lower triangular storage of matrix bold upper A 3 defined by

data ldata;
   input parm row col value;
   datalines;
3  2  1  2
3  1  2  5
;

is

Start 4 By 4 Matrix 1st Row 1st Column 0 2nd Column Blank 3rd Column Blank 4th Column Blank 2nd Row 1st Column 5 2nd Column 0 3rd Column Blank 4th Column Blank 3rd Row 1st Column 0 2nd Column 0 3rd Column 0 4th Column Blank 4th Row 1st Column 0 2nd Column 0 3rd Column 0 4th Column 0 EndMatrix
NOFULLZ

eliminates the columns in bold upper Z corresponding to missing levels of random effects involving CLASS variables. By default, these columns are included in bold upper Z. It is sufficient to specify the NOFULLZ option on any G-side RANDOM statement.

RESIDUAL
RSIDE

specifies that the random effects listed in this statement be R-side effects. You use the RESIDUAL option in the RANDOM statement if the nature of the covariance structure requires you to specify an effect. For example, if it is necessary to order the columns of the R-side AR(1) covariance structure by the time variable, you can use the RESIDUAL option as in the following statements:

class time id;
random time / subject=id type=ar(1) residual;
SOLUTION
S

requests that the solution ModifyingAbove bold-italic gamma With caret for the random-effects parameters be produced, if the statement defines G-side random effects.

The numbers displayed in the Std Err Pred column of the "Solution for Random Effects" table are not the standard errors of the ModifyingAbove bold-italic gamma With caret displayed in the Estimate column; rather, they are the square roots of the prediction errors ModifyingAbove bold-italic gamma With caret Subscript i Baseline minus bold-italic gamma Subscript i, where ModifyingAbove bold-italic gamma With caret Subscript i is the predictor of the ith random effect and bold-italic gamma Subscript i is the ith random effect. In pseudo-likelihood methods that are based on linearization, these EBLUPs are the estimated best linear unbiased predictors in the linear mixed pseudo-model. In models fit by maximum likelihood by using the Laplace approximation or by using adaptive quadrature, the SOLUTION option displays the empirical Bayes estimates (EBE) of bold-italic gamma Subscript i.

SUBJECT=effect
SUB=effect

identifies the subjects in your generalized linear mixed model. Complete independence is assumed across subjects. Specifying a subject effect is equivalent to nesting all other effects in the RANDOM statement within the subject effect.

Continuous variables and computed variables are permitted with the SUBJECT= option. PROC GLIMMIX does not sort by the values of the continuous variable but considers the data to be from a new subject whenever the value of the continuous variable changes from the previous observation. Using a continuous variable can decrease execution time for models with a large number of subjects and also prevents the production of a large "Class Levels Information" table.

TYPE=covariance-structure

specifies the covariance structure of bold upper G for G-side effects and the covariance structure of bold upper R for R-side effects.

Although a variety of structures are available, many applications call for either simple diagonal (TYPE=VC) or unstructured covariance matrices. The TYPE=VC (variance components) option is the default structure, and it models a different variance component for each random effect. It is recommended to model unstructured covariance matrices in terms of their Cholesky parameterization (TYPE=CHOL) rather than TYPE=UN.

If you want different covariance structures in different parts of bold upper G, you must use multiple RANDOM statements with different TYPE= options.

Valid values for covariance-structure are as follows. Examples are shown in Table 21.

The variances and covariances in the formulas that follow in the TYPE= descriptions are expressed in terms of generic random variables xi Subscript i and xi Subscript j. They represent the G-side random effects or the residual random variables for which the bold upper G or bold upper R matrices are constructed.

ANTE(1)

specifies a first-order ante-dependence structure (Kenward 1987; Patel 1991) parameterized in terms of variances and correlation parameters. If t ordered random variables xi 1 comma ellipsis comma xi Subscript t Baseline have a first-order ante-dependence structure, then each xi Subscript j, j greater-than 1, is independent of all other xi Subscript k Baseline comma k less-than j, given xi Subscript j minus 1. This Markovian structure is characterized by its inverse variance matrix, which is tridiagonal. Parameterizing an ANTE(1) structure for a random vector of size t requires 2t – 1 parameters: variances sigma 1 squared comma ellipsis comma sigma Subscript t Superscript 2 and t – 1 correlation parameters rho 1 comma ellipsis comma rho Subscript t minus 1 Baseline. The covariances among random variables xi Subscript i and xi Subscript j are then constructed as

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartRoot sigma Subscript i Superscript 2 Baseline sigma Subscript j Superscript 2 Baseline EndRoot product Underscript k equals i Overscript j minus 1 Endscripts rho Subscript k

PROC GLIMMIX constrains the correlation parameters to satisfy StartAbsoluteValue rho Subscript k Baseline EndAbsoluteValue less-than 1 comma for-all k. For variable-order ante-dependence models see Macchiavelli and Arnold (1994).

AR(1)

specifies a first-order autoregressive structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared rho Superscript StartAbsoluteValue i Super Superscript asterisk Superscript minus j Super Superscript asterisk Superscript EndAbsoluteValue

The values i Superscript asterisk and j Superscript asterisk are derived for the ith and jth observations, respectively, and are not necessarily the observation numbers. For example, in the following statements the values correspond to the class levels for the time effect of the ith and jth observation within a particular subject:

proc glimmix;
   class time patient;
   model y = x x*x;
   random time / sub=patient type=ar(1) residual;
run;

PROC GLIMMIX imposes the constraint StartAbsoluteValue rho EndAbsoluteValue less-than 1 for stationarity.

ARH(1)

specifies a heterogeneous first-order autoregressive structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartRoot sigma Subscript i Superscript 2 Baseline sigma Subscript j Superscript 2 Baseline EndRoot rho Superscript StartAbsoluteValue i Super Superscript asterisk Superscript minus j Super Superscript asterisk Superscript EndAbsoluteValue

with StartAbsoluteValue rho EndAbsoluteValue less-than 1. This covariance structure has the same correlation pattern as the TYPE=AR(1) structure, but the variances are allowed to differ.

ARMA(1,1)

specifies the first-order autoregressive moving-average structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma squared 2nd Column i equals j 2nd Row 1st Column sigma squared gamma rho Superscript StartAbsoluteValue i Super Superscript asterisk Superscript minus j Super Superscript asterisk Superscript EndAbsoluteValue minus 1 Baseline 2nd Column i not-equals j EndLayout

Here, rho is the autoregressive parameter, gamma models a moving-average component, and sigma squared is a scale parameter. In the notation of Fuller (1976, p. 68), rho equals theta 1 and

gamma equals StartFraction left-parenthesis 1 plus b 1 theta 1 right-parenthesis left-parenthesis theta 1 plus b 1 right-parenthesis Over 1 plus b 1 squared plus 2 b 1 theta 1 EndFraction

The example in Table 21 and StartAbsoluteValue b 1 EndAbsoluteValue less-than 1 imply that

b 1 equals StartFraction beta minus StartRoot beta squared minus 4 alpha squared EndRoot Over 2 alpha EndFraction

where alpha equals gamma minus rho and beta equals 1 plus rho squared minus 2 gamma rho. PROC GLIMMIX imposes the constraints StartAbsoluteValue rho EndAbsoluteValue less-than 1 and StartAbsoluteValue gamma EndAbsoluteValue less-than 1 for stationarity, although for some values of rho and gamma in this region the resulting covariance matrix is not positive definite. When the estimated value of rho becomes negative, the computed covariance is multiplied by cosine left-parenthesis pi d Subscript i j Baseline right-parenthesis to account for the negativity.

CHOL<(q)>

specifies an unstructured variance-covariance matrix parameterized through its Cholesky root. This parameterization ensures that the resulting variance-covariance matrix is at least positive semidefinite. If all diagonal values are nonzero, it is positive definite. For example, a 2 times 2 unstructured covariance matrix can be written as

normal upper V normal a normal r left-bracket bold-italic xi right-bracket equals Start 2 By 2 Matrix 1st Row 1st Column theta 1 2nd Column theta 12 2nd Row 1st Column theta 12 2nd Column theta 2 EndMatrix

Without imposing constraints on the three parameters, there is no guarantee that the estimated variance matrix is positive definite. Even if theta 1 and theta 2 are nonzero, a large value for theta 12 can lead to a negative eigenvalue of normal upper V normal a normal r left-bracket bold-italic xi right-bracket. The Cholesky root of a positive definite matrix bold upper A is a lower triangular matrix bold upper C such that bold upper C bold upper C Superscript prime Baseline equals bold upper A. The Cholesky root of the above 2 times 2 matrix can be written as

bold upper C equals Start 2 By 2 Matrix 1st Row 1st Column alpha 1 2nd Column 0 2nd Row 1st Column alpha 12 2nd Column alpha 2 EndMatrix

The elements of the unstructured variance matrix are then simply theta 1 equals alpha 1 squared, theta 12 equals alpha 1 alpha 12, and theta 2 equals alpha 12 squared plus alpha 2 squared. Similar operations yield the generalization to covariance matrices of higher orders.

For example, the following statements model the covariance matrix of each subject as an unstructured matrix:

proc glimmix;
   class sub;
   model y = x;
   random _residual_ / subject=sub type=un;
run;

The next set of statements accomplishes the same, but the estimated bold upper R matrix is guaranteed to be nonnegative definite:

proc glimmix;
   class sub;
   model y = x;
   random _residual_ / subject=sub type=chol;
run;

The GLIMMIX procedure constrains the diagonal elements of the Cholesky root to be positive. This guarantees a unique solution when the matrix is positive definite.

The optional order parameter q greater-than 0 determines how many bands below the diagonal are modeled. Elements in the lower triangular portion of bold upper C in bands higher than q are set to zero. If you consider the resulting covariance matrix bold upper A equals bold upper C bold upper C prime, then the order parameter has the effect of zeroing all off-diagonal elements that are at least q positions away from the diagonal.

Because of its good computational and statistical properties, the Cholesky root parameterization is generally recommended over a completely unstructured covariance matrix (TYPE=UN). However, it is computationally slightly more involved.

CS

specifies the compound-symmetry structure, which has constant variance and constant covariance

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column phi plus sigma 2nd Column i equals j 2nd Row 1st Column sigma 2nd Column i not-equals j EndLayout

The compound symmetry structure arises naturally with nested random effects, such as when subsampling error is nested within experimental error. The models constructed with the following two sets of GLIMMIX statements have the same marginal variance matrix, provided sigma is positive:

proc glimmix;
   class block A;
   model y = block A;
   random block*A / type=vc;
run;
proc glimmix;
   class block A;
   model y = block A;
   random _residual_ / subject=block*A
                       type=cs;
run;

In the first case, the block*A random effect models the G-side experimental error. Because the distribution defaults to the normal, the bold upper R matrix is of form phi bold upper I (see Table 22), and phi is the subsampling error variance. The marginal variance for the data from a particular experimental unit is thus sigma Subscript b asterisk a Superscript 2 Baseline bold upper J plus phi bold upper I. This matrix is of compound symmetric form.

Hierarchical random assignments or selections, such as subsampling or split-plot designs, give rise to compound symmetric covariance structures. This implies exchangeability of the observations on the subunit, leading to constant correlations between the observations. Compound symmetric structures are thus usually not appropriate for processes where correlations decline according to some metric, such as spatial and temporal processes.

Note that R-side compound-symmetry structures do not impose any constraint on sigma. You can thus use an R-side TYPE=CS structure to emulate a variance-component model with unbounded estimate of the variance component.

CSH

specifies the heterogeneous compound-symmetry structure, which is an equi-correlation structure but allows for different variances

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column StartRoot sigma Subscript i Superscript 2 Baseline sigma Subscript j Superscript 2 Baseline EndRoot 2nd Column i equals j 2nd Row 1st Column rho StartRoot sigma Subscript i Superscript 2 Baseline sigma Subscript j Superscript 2 Baseline EndRoot 2nd Column i not-equals j EndLayout
FA(q)

specifies the factor-analytic structure with q factors (Jennrich and Schluchter 1986). This structure is of the form bold upper Lamda bold upper Lamda prime plus bold upper D, where bold upper Lamda is a t times q rectangular matrix and bold upper D is a t times t diagonal matrix with t different parameters. When q greater-than 1, the elements of bold upper Lamda in its upper-right corner (that is, the elements in the ith row and jth column for j greater-than i) are set to zero to fix the rotation of the structure.

FA0(q)

specifies a factor-analytic structure with q factors of the form normal upper V normal a normal r left-bracket bold-italic xi right-bracket equals bold upper Lamda bold upper Lamda prime, where bold upper Lamda is a t times q rectangular matrix and t is the dimension of bold upper Y. When q greater-than 1, bold upper Lamda is a lower triangular matrix. When q less-than t—that is, when the number of factors is less than the dimension of the matrix—this structure is nonnegative definite but not of full rank. In this situation, you can use it to approximate an unstructured covariance matrix.

HF

specifies a covariance structure that satisfies the general Huynh-Feldt condition (Huynh and Feldt 1970). For a random vector with t elements, this structure has t plus 1 positive parameters and covariances

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma Subscript i Superscript 2 Baseline 2nd Column i equals j 2nd Row 1st Column 0.5 left-parenthesis sigma Subscript i Superscript 2 Baseline plus sigma Subscript j Superscript 2 Baseline right-parenthesis minus lamda 2nd Column i not-equals j EndLayout

A covariance matrix bold upper Sigma generally satisfies the Huynh-Feldt condition if it can be written as bold upper Sigma equals bold-italic tau bold 1 Superscript prime Baseline plus bold 1 bold-italic tau Superscript prime Baseline plus lamda bold upper I. The preceding parameterization chooses tau Subscript i Baseline equals 0.5 left-parenthesis sigma Subscript i Superscript 2 Baseline minus lamda right-parenthesis. Several simpler covariance structures give rise to covariance matrices that also satisfy the Huynh-Feldt condition. For example, TYPE=CS, TYPE=VC, and TYPE=UN(1) are nested within TYPE=HF. You can use the COVTEST statement to test the HF structure against one of these simpler structures. Note also that the HF structure is nested within an unstructured covariance matrix.

The TYPE=HF covariance structure can be sensitive to the choice of starting values and the default MIVQUE(0) starting values can be poor for this structure; you can supply your own starting values with the PARMS statement.

LIN(q)

specifies a general linear covariance structure with q parameters. This structure consists of a linear combination of known matrices that you input with the LDATA= option. Suppose that you want to model the covariance of a random vector of length t, and further suppose that bold upper A 1 comma ellipsis comma bold upper A Subscript q Baseline are symmetric left-parenthesis t times t) matrices constructed from the information in the LDATA= data set. Then,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma-summation Underscript k equals 1 Overscript q Endscripts theta Subscript k Baseline left-bracket bold upper A Subscript k Baseline right-bracket Subscript i j

where left-bracket bold upper A Subscript k Baseline right-bracket Subscript i j denotes the element in row i, column j of matrix bold upper A Subscript k.

Linear structures are very flexible and general. You need to exercise caution to ensure that the variance matrix is positive definite. Note that PROC GLIMMIX does not impose boundary constraints on the parameters theta 1 comma ellipsis comma theta Subscript k Baseline of a general linear covariance structure. For example, if classification variable A has 6 levels, the following statements fit a variance component structure for the random effect without boundary constraints:

data ldata;
   retain parm 1 value 1;
   do row=1 to 6; col=row; output; end;
run;

proc glimmix data=MyData;
   class A B;
   model Y = B;
   random A / type=lin(1) ldata=ldata;
run;
PSPLINE<(options)>

requests that PROC GLIMMIX form a B-spline basis and fits a penalized B-spline (P-spline, Eilers and Marx 1996) with random spline coefficients. This covariance structure is available only for G-side random effects and only a single continuous random effect can be specified with TYPE=PSPLINE. As for TYPE=RSMOOTH, PROC GLIMMIX forms a modified bold upper Z matrix and fits a mixed model in which the random variables associated with the columns of bold upper Z are independent with a common variance. The bold upper Z matrix is constructed as follows.

Denote as bold upper Z overTilde the left-parenthesis n times upper K right-parenthesis matrix of B-splines of degree d and denote as bold upper D Subscript r the left-parenthesis upper K minus r times upper K right-parenthesis matrix of rth-order differences. For example, for K = 5,

StartLayout 1st Row 1st Column bold upper D 1 2nd Column equals Start 4 By 5 Matrix 1st Row 1st Column 1 2nd Column negative 1 3rd Column 0 4th Column 0 5th Column 0 2nd Row 1st Column 0 2nd Column 1 3rd Column negative 1 4th Column 0 5th Column 0 3rd Row 1st Column 0 2nd Column 0 3rd Column 1 4th Column negative 1 5th Column 0 4th Row 1st Column 0 2nd Column 0 3rd Column 0 4th Column 1 5th Column negative 1 EndMatrix 2nd Row 1st Column bold upper D 2 2nd Column equals Start 3 By 5 Matrix 1st Row 1st Column 1 2nd Column negative 2 3rd Column 1 4th Column 0 5th Column 0 2nd Row 1st Column 0 2nd Column 1 3rd Column negative 2 4th Column 1 5th Column 0 3rd Row 1st Column 0 2nd Column 0 3rd Column 1 4th Column negative 2 5th Column 1 EndMatrix 3rd Row 1st Column bold upper D 3 2nd Column equals Start 2 By 5 Matrix 1st Row 1st Column 1 2nd Column negative 3 3rd Column 3 4th Column negative 1 5th Column 0 2nd Row 1st Column 0 2nd Column 1 3rd Column negative 3 4th Column 3 5th Column negative 1 EndMatrix EndLayout

Then, the bold upper Z matrix used in fitting the mixed model is the left-parenthesis n times upper K minus r right-parenthesis matrix

bold upper Z equals bold upper Z overTilde left-parenthesis bold upper D prime Subscript r Baseline bold upper D Subscript r Baseline right-parenthesis Superscript minus Baseline bold upper D prime Subscript r

The construction of the B-spline knots is controlled with the KNOTMETHOD= EQUAL(m) option and the DEGREE=d suboption of TYPE=PSPLINE. The total number of knots equals the number m of equally spaced interior knots plus d knots at the low end and max left-brace 1 comma d right-brace knots at the high end. The number of columns in the B-spline basis equals K = m + d + 1. By default, the interior knots exclude the minimum and maximum of the random-effect values and are based on m – 1 equally spaced intervals. Suppose x Subscript left-parenthesis 1 right-parenthesis and x Subscript left-parenthesis n right-parenthesis are the smallest and largest random-effect values; then interior knots are placed at

x Subscript left-parenthesis 1 right-parenthesis Baseline plus j left-parenthesis x Subscript left-parenthesis n right-parenthesis Baseline minus x Subscript left-parenthesis 1 right-parenthesis Baseline right-parenthesis slash left-parenthesis m plus 1 right-parenthesis comma j equals 1 comma ellipsis comma m

In addition, d evenly spaced exterior knots are placed below x Subscript left-parenthesis 1 right-parenthesis and max left-brace d comma 1 right-brace exterior knots are placed above x Subscript left-parenthesis m right-parenthesis. The exterior knots are evenly spaced and start at x Subscript left-parenthesis 1 right-parenthesis Baseline plus-or-minus 100 times the machine epsilon. For example, based on the defaults d = 3, r = 3, the following statements lead to 26 total knots and 21 columns in bold upper Z, m = 20, K = m + d + 1 = 24, Kr = 21:

proc glimmix;
   model y = x;
   random x / type=pspline knotmethod=equal(20);
run;

Details about the computation and properties of B-splines can be found in De Boor (2001). You can extend or limit the range of the knots with the KNOTMIN= and KNOTMAX= options. Table 20 lists some of the parameters that control this covariance type and their relationships.

Table 20: P-Spline Parameters

Parameter Description
d Degree of B-spline, default d = 3
r Order of differencing in construction of bold upper D Subscript r, default r = 3
m Number of interior knots, default m equals 10
m plus d plus max left-brace 1 comma d right-brace Total number of knots
upper K equals m plus d plus 1 Number of columns in B-spline basis
upper K minus r Number of columns in bold upper Z


You can specify the following options for TYPE=PSPLINE:

DEGREE=d

specifies the degree of the B-spline. The default is d = 3.

DIFFORDER=r

specifies the order of the differencing matrix bold upper D Subscript r. The default and maximum is r = 3.

RSMOOTH<(m | NOLOG)>

specifies a radial smoother covariance structure for G-side random effects. This results in an approximate low-rank thin-plate spline where the smoothing parameter is obtained by the estimation method selected with the METHOD= option of the PROC GLIMMIX statement. The smoother is based on the automatic smoother in Ruppert, Wand, and Carroll (2003, Chapter 13.4–13.5), but with a different method of selecting the spline knots. See the section Radial Smoothing Based on Mixed Models for further details about the construction of the smoother and the knot selection.

Radial smoothing is possible in one or more dimensions. A univariate smoother is obtained with a single random effect, while multiple random effects in a RANDOM statement yield a multivariate smoother. Only continuous random effects are permitted with this covariance structure. If n Subscript r denotes the number of continuous random effects in the RANDOM statement, then the covariance structure of the random effects bold-italic gamma is determined as follows. Suppose that bold z Subscript i denotes the vector of random effects for the ith observation. Let bold-italic tau Subscript k denote the left-parenthesis n Subscript r Baseline times 1 right-parenthesis vector of knot coordinates, k equals 1 comma ellipsis comma upper K, and K is the total number of knots. The Euclidean distance between the knots is computed as

d Subscript k p Baseline equals StartAbsoluteValue EndAbsoluteValue bold-italic tau Subscript k Baseline minus bold-italic tau Subscript p Baseline StartAbsoluteValue EndAbsoluteValue equals StartRoot sigma-summation Underscript j equals 1 Overscript n Subscript r Baseline Endscripts left-parenthesis tau Subscript j k Baseline minus tau Subscript j p Baseline right-parenthesis squared EndRoot

and the distance between knots and effects is computed as

h Subscript i k Baseline equals StartAbsoluteValue EndAbsoluteValue bold z Subscript i Baseline minus bold-italic tau Subscript k Baseline StartAbsoluteValue EndAbsoluteValue equals StartRoot sigma-summation Underscript j equals 1 Overscript n Subscript r Baseline Endscripts left-parenthesis z Subscript i j Baseline minus tau Subscript j k Baseline right-parenthesis squared EndRoot

The bold upper Z matrix for the GLMM is constructed as

bold upper Z equals bold upper Z overTilde bold upper Omega Superscript negative 1 slash 2

where the left-parenthesis n times upper K right-parenthesis matrix bold upper Z overTilde has typical element

left-bracket bold upper Z overTilde right-bracket Subscript i k Baseline equals StartLayout Enlarged left-brace 1st Row 1st Column h Subscript i k Superscript p Baseline 2nd Column n Subscript r Baseline normal o normal d normal d 2nd Row 1st Column h Subscript i k Superscript p Baseline log left-brace h Subscript i k Baseline right-brace 2nd Column n Subscript r Baseline normal e normal v normal e normal n EndLayout

and the left-parenthesis upper K times upper K right-parenthesis matrix bold upper Omega has typical element

left-bracket bold upper Omega right-bracket Subscript k p Baseline equals StartLayout Enlarged left-brace 1st Row 1st Column d Subscript k p Superscript p Baseline 2nd Column n Subscript r Baseline normal o normal d normal d 2nd Row 1st Column d Subscript k p Superscript p Baseline log left-brace d Subscript k p Baseline right-brace 2nd Column n Subscript r Baseline normal e normal v normal e normal n EndLayout

The exponent in these expressions equals p equals 2 m minus n Subscript r, where the optional value m corresponds to the derivative penalized in the thin-plate spline. A larger value of m will yield a smoother fit. The GLIMMIX procedure requires p > 0 and chooses by default m = 2 if n Subscript r Baseline less-than 3 and m equals n Subscript r Baseline slash 2 plus 1 otherwise. The NOLOG option removes the log left-brace h Subscript i k Baseline right-brace and log left-brace d Subscript k p Baseline right-brace terms from the computation of the bold upper Z overTilde and bold upper Omega matrices when n Subscript r is even; this yields invariance under rescaling of the coordinates.

Finally, the components of bold-italic gamma are assumed to have equal variance sigma Subscript r Superscript 2. The "smoothing parameter" lamda of the low-rank spline is related to the variance components in the model, lamda squared equals f left-parenthesis phi comma sigma Subscript r Superscript 2 Baseline right-parenthesis. See Ruppert, Wand, and Carroll (2003) for details. If the conditional distribution does not provide a scale parameter phi, you can add a single R-side residual parameter.

The knot selection is controlled with the KNOTMETHOD= option. The GLIMMIX procedure selects knots automatically based on the vertices of a k-d tree or reads knots from a data set that you supply. See the section Radial Smoothing Based on Mixed Models for further details on radial smoothing in the GLIMMIX procedure and its connection to a mixed model formulation.

SIMPLE

is an alias for TYPE=VC.

SP(EXP)(c-list)

models an exponential spatial or temporal covariance structure, where the covariance between two observations depends on a distance metric d Subscript i j. The c-list contains the names of the numeric variables used as coordinates to determine distance. For a stochastic process in upper R Superscript k, there are k elements in c-list. If the left-parenthesis k times 1 right-parenthesis vectors of coordinates for observations i and j are bold c Subscript i and bold c Subscript j, then PROC GLIMMIX computes the Euclidean distance

d Subscript i j Baseline equals StartAbsoluteValue EndAbsoluteValue bold c Subscript i Baseline minus bold c Subscript j Baseline StartAbsoluteValue EndAbsoluteValue equals StartRoot sigma-summation Underscript m equals 1 Overscript k Endscripts left-parenthesis c Subscript m i Baseline minus c Subscript m j Baseline right-parenthesis squared EndRoot

The covariance between two observations is then

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared exp left-brace minus d Subscript i j Baseline slash alpha right-brace

The parameter alpha is not what is commonly referred to as the range parameter in geostatistical applications. The practical range of a (second-order stationary) spatial process is the distance d Superscript left-parenthesis p right-parenthesis at which the correlations fall below 0.05. For the SP(EXP) structure, this distance is d Superscript left-parenthesis p right-parenthesis Baseline equals 3 alpha. PROC GLIMMIX constrains alpha to be positive.

SP(GAU)(c-list)

models a Gaussian covariance structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared exp left-brace minus d Subscript i j Superscript 2 Baseline slash alpha squared right-brace

See TYPE=TYPE=SP(EXP) for the computation of the distance d Subscript i j. The parameter alpha is related to the range of the process as follows. If the practical range d Superscript left-parenthesis p right-parenthesis is defined as the distance at which the correlations fall below 0.05, then d Superscript left-parenthesis p right-parenthesis Baseline equals StartRoot 3 EndRoot alpha. PROC GLIMMIX constrains alpha to be positive. See TYPE=SP(EXP) for the computation of the distance d Subscript i j from the variables specified in c-list.

SP(LEAR)(c-list)

models a linear exponent autoregressive covariance structure as proposed by Simpson et al. (2010). For two observations with distance metric d Subscript i j, the covariance is

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared StartLayout Enlarged left-brace 1st Row 1st Column rho Superscript d Super Subscript normal m normal i normal n Superscript plus delta left-bracket left-parenthesis d Super Subscript i j Superscript minus d Super Subscript normal m normal i normal n Superscript right-parenthesis slash left-parenthesis d Super Subscript normal m normal a normal x Superscript minus d Super Subscript normal m normal i normal n Superscript right-parenthesis right-bracket Baseline 2nd Column i not-equals j 2nd Row 1st Column 1 2nd Column i equals j EndLayout

where d Subscript normal m normal i normal n and d Subscript normal m normal a normal x are the smallest and largest distances between any two observations, delta greater-than-or-equal-to 0 is the decay speed, and 0 less-than-or-equal-to rho less-than 1. See TYPE=SP(EXP) for the computation of the distance d Subscript i j from the variables specified in c-list. When the estimated value of rho becomes negative, PROC GLIMMIX multiplies the computed covariance by cosine left-parenthesis pi d Subscript i j Baseline right-parenthesis to account for the negativity. When d Subscript normal m normal i normal n Baseline equals d Subscript normal m normal a normal x, PROC GLIMMIX sets the computed covariance to sigma squared rho Superscript d Super Subscript normal m normal i normal n. Note that GROUP= effect is not supported for TYPE=SP(LEAR).

For power analysis of repeated measures designs that have a LEAR correlation structure, see the section POWER Statement in Chapter 55, The GLMPOWER Procedure.

SP(MAT)(c-list)

models a covariance structure in the Matérn class of covariance functions (Matérn 1986). The covariance is expressed in the parameterization of Handcock and Stein (1993); Handcock and Wallis (1994); it can be written as

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared StartFraction 1 Over normal upper Gamma left-parenthesis nu right-parenthesis EndFraction left-parenthesis StartFraction d Subscript i j Baseline StartRoot nu EndRoot Over rho EndFraction right-parenthesis Superscript nu Baseline 2 upper K Subscript nu Baseline left-parenthesis StartFraction 2 d Subscript i j Baseline StartRoot nu EndRoot Over rho EndFraction right-parenthesis

The function upper K Subscript nu is the modified Bessel function of the second kind of (real) order nu greater-than 0. The smoothness (continuity) of a stochastic process with covariance function in the Matérn class increases with nu. This class thus enables data-driven estimation of the smoothness properties of the process. The covariance is identical to the exponential model for nu equals 0.5 (TYPE=SP(EXP)(c-list)), while for nu equals 1 the model advocated by Whittle (1954) results. As nu right-arrow normal infinity, the model approaches the Gaussian covariance structure (TYPE=SP(GAU)(c-list)).

Note that the MIXED procedure offers covariance structures in the Matérn class in two parameterizations, TYPE=SP(MATERN) and TYPE=SP(MATHSW). The TYPE=SP(MAT) in the GLIMMIX procedure is equivalent to TYPE=SP(MATHSW) in the MIXED procedure.

Computation of the function upper K Subscript nu and its derivatives is numerically demanding; fitting models with Matérn covariance structures can be time-consuming. Good starting values are essential.

SP(POW)(c-list)

models a power covariance structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared rho Superscript d Super Subscript i j

where rho greater-than-or-equal-to 0. This is a reparameterization of the exponential structure, TYPE=SP(EXP). Specifically, log left-brace rho right-brace equals negative 1 slash alpha. See TYPE=SP(EXP) for the computation of the distance d Subscript i j from the variables specified in c-list. When the estimated value of rho becomes negative, the computed covariance is multiplied by cosine left-parenthesis pi d Subscript i j Baseline right-parenthesis to account for the negativity.

SP(POWA)(c-list)

models an anisotropic power covariance structure in k dimensions, provided that the coordinate list c-list has k elements. If c Subscript i m denotes the coordinate for the ith observation of the mth variable in c-list, the covariance between two observations is given by

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma squared rho 1 Superscript StartAbsoluteValue c Super Subscript i Baseline 1 Superscript minus c Super Subscript j Baseline 1 Superscript EndAbsoluteValue Baseline rho 2 Superscript StartAbsoluteValue c Super Subscript i Baseline 2 Superscript minus c Super Subscript j Baseline 2 Superscript EndAbsoluteValue Baseline ellipsis rho Subscript k Superscript StartAbsoluteValue c Super Subscript i k Superscript minus c Super Subscript j k Superscript EndAbsoluteValue

Note that for k = 1, TYPE=SP(POWA) is equivalent to TYPE=SP(POW), which is itself a reparameterization of TYPE=SP(EXP). When the estimated value of rho Subscript m becomes negative, the computed covariance is multiplied by cosine left-parenthesis pi StartAbsoluteValue c Subscript i m Baseline minus c Subscript j m Baseline EndAbsoluteValue right-parenthesis to account for the negativity.

SP(SPH)(c-list)

models a spherical covariance structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma squared StartSet 1 minus StartFraction 3 d Subscript i j Baseline Over 2 alpha EndFraction plus one-half left-parenthesis StartFraction d Subscript i j Baseline Over alpha EndFraction right-parenthesis cubed EndSet 2nd Column d Subscript i j Baseline less-than-or-equal-to alpha 2nd Row 1st Column 0 2nd Column d Subscript i j Baseline greater-than alpha EndLayout

The spherical covariance structure has a true range parameter. The covariances between observations are exactly zero when their distance exceeds alpha. See TYPE=SP(EXP) for the computation of the distance d Subscript i j from the variables specified in c-list.

TOEP

models a Toeplitz covariance structure. This structure can be viewed as an autoregressive structure with order equal to the dimension of the matrix,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma squared 2nd Column i equals j 2nd Row 1st Column sigma Subscript StartAbsoluteValue i minus j EndAbsoluteValue Baseline 2nd Column i not-equals j EndLayout
TOEP(q)

specifies a banded Toeplitz structure,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma squared 2nd Column i equals j 2nd Row 1st Column sigma Subscript StartAbsoluteValue i minus j EndAbsoluteValue Baseline 2nd Column StartAbsoluteValue i minus j EndAbsoluteValue less-than q EndLayout

This can be viewed as a moving-average structure with order equal to q – 1. The specification TYPE=TOEP(1) is the same as sigma squared bold upper I, and it can be useful for specifying the same variance component for several effects.

TOEPH<(q)>

models a Toeplitz covariance structure. The correlations of this structure are banded as the TOEP or TOEP(q) structures, but the variances are allowed to vary:

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals StartLayout Enlarged left-brace 1st Row 1st Column sigma Subscript i Superscript 2 Baseline 2nd Column i equals j 2nd Row 1st Column rho Subscript StartAbsoluteValue i minus j EndAbsoluteValue Baseline StartRoot sigma Subscript i Superscript 2 Baseline sigma Subscript j Superscript 2 Baseline EndRoot 2nd Column i not-equals j EndLayout

The correlation parameters satisfy StartAbsoluteValue rho Subscript StartAbsoluteValue i minus j EndAbsoluteValue Baseline EndAbsoluteValue less-than 1. If you specify the optional value q, the correlation parameters with StartAbsoluteValue i minus j EndAbsoluteValue greater-than-or-equal-to q are set to zero, creating a banded correlation structure. The specification TYPE=TOEPH(1) results in a diagonal covariance matrix with heterogeneous variances.

UN<(q)>

specifies a completely general (unstructured) covariance matrix parameterized directly in terms of variances and covariances,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma Subscript i j

The variances are constrained to be nonnegative, and the covariances are unconstrained. This structure is not constrained to be nonnegative definite in order to avoid nonlinear constraints; however, you can use the TYPE=CHOL structure if you want this constraint to be imposed by a Cholesky factorization. If you specify the order parameter q, then PROC GLIMMIX estimates only the first q bands of the matrix, setting elements in all higher bands equal to 0.

UNR<(q)>

specifies a completely general (unstructured) covariance matrix parameterized in terms of variances and correlations,

normal upper C normal o normal v left-bracket xi Subscript i Baseline comma xi Subscript j Baseline right-bracket equals sigma Subscript i Baseline sigma Subscript j Baseline rho Subscript i j

where sigma Subscript i denotes the standard deviation and the correlation rho Subscript i j is zero when i equals j and when StartAbsoluteValue i minus j EndAbsoluteValue greater-than-or-equal-to q, provided the order parameter q is given. This structure fits the same model as the TYPE=UN(q) option, but with a different parameterization. The ith variance parameter is sigma Subscript i Superscript 2. The parameter rho Subscript i j is the correlation between the ith and jth measurements; it satisfies StartAbsoluteValue rho Subscript i j Baseline EndAbsoluteValue less-than 1. If you specify the order parameter q, then PROC GLIMMIX estimates only the first q bands of the matrix, setting all higher bands equal to zero.

VC

specifies standard variance components and is the default structure for both G-side and R-side covariance structures. In a G-side covariance structure, a distinct variance component is assigned to each effect. In an R-side structure TYPE=VC is usually used only to add overdispersion effects or with the GROUP= option to specify a heterogeneous variance model.

Table 21: Covariance Structure Examples

Description Structure Example
Variance
Components
VC (default) Start 4 By 4 Matrix 1st Row 1st Column sigma Subscript upper B Superscript 2 2nd Column 0 3rd Column 0 4th Column 0 2nd Row 1st Column 0 2nd Column sigma Subscript upper B Superscript 2 3rd Column 0 4th Column 0 3rd Row 1st Column 0 2nd Column 0 3rd Column sigma Subscript upper A upper B Superscript 2 4th Column 0 4th Row 1st Column 0 2nd Column 0 3rd Column 0 4th Column sigma Subscript upper A upper B Superscript 2 EndMatrix
Compound
Symmetry
CS Start 4 By 4 Matrix 1st Row 1st Column sigma plus phi 2nd Column sigma 3rd Column sigma 4th Column sigma 2nd Row 1st Column sigma 2nd Column sigma plus phi 3rd Column sigma 4th Column sigma 3rd Row 1st Column sigma 2nd Column sigma 3rd Column sigma plus phi 4th Column sigma 4th Row 1st Column sigma 2nd Column sigma 3rd Column sigma 4th Column sigma plus phi EndMatrix
Heterogeneous
CS
CSH Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 1 sigma 2 rho 3rd Column sigma 1 sigma 3 rho 4th Column sigma 1 sigma 4 rho 2nd Row 1st Column sigma 2 sigma 1 rho 2nd Column sigma 2 squared 3rd Column sigma 2 sigma 3 rho 4th Column sigma 2 sigma 4 rho 3rd Row 1st Column sigma 3 sigma 1 rho 2nd Column sigma 3 sigma 2 rho 3rd Column sigma 3 squared 4th Column sigma 3 sigma 4 rho 4th Row 1st Column sigma 4 sigma 1 rho 2nd Column sigma 4 sigma 2 rho 3rd Column sigma 4 sigma 3 rho 4th Column sigma 4 squared EndMatrix
First-Order
Autoregressive
AR(1) sigma squared Start 4 By 4 Matrix 1st Row 1st Column 1 2nd Column rho 3rd Column rho squared 4th Column rho cubed 2nd Row 1st Column rho 2nd Column 1 3rd Column rho 4th Column rho squared 3rd Row 1st Column rho squared 2nd Column rho 3rd Column 1 4th Column rho 4th Row 1st Column rho cubed 2nd Column rho squared 3rd Column rho 4th Column 1 EndMatrix
Heterogeneous
AR(1)
ARH(1) Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 1 sigma 2 rho 3rd Column sigma 1 sigma 3 rho squared 4th Column sigma 1 sigma 4 rho cubed 2nd Row 1st Column sigma 2 sigma 1 rho 2nd Column sigma 2 squared 3rd Column sigma 2 sigma 3 rho 4th Column sigma 2 sigma 4 rho squared 3rd Row 1st Column sigma 3 sigma 1 rho squared 2nd Column sigma 3 sigma 2 rho 3rd Column sigma 3 squared 4th Column sigma 3 sigma 4 rho 4th Row 1st Column sigma 4 sigma 1 rho cubed 2nd Column sigma 4 sigma 2 rho 3rd Column sigma 4 sigma 3 rho 4th Column sigma 4 squared EndMatrix
Unstructured UN Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 21 3rd Column sigma 31 4th Column sigma 41 2nd Row 1st Column sigma 21 2nd Column sigma 2 squared 3rd Column sigma 32 4th Column sigma 42 3rd Row 1st Column sigma 31 2nd Column sigma 32 3rd Column sigma 3 squared 4th Column sigma 43 4th Row 1st Column sigma 41 2nd Column sigma 42 3rd Column sigma 43 4th Column sigma 4 squared EndMatrix
Banded Main
Diagonal
UN(1) Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column 0 3rd Column 0 4th Column 0 2nd Row 1st Column 0 2nd Column sigma 2 squared 3rd Column 0 4th Column 0 3rd Row 1st Column 0 2nd Column 0 3rd Column sigma 3 squared 4th Column 0 4th Row 1st Column 0 2nd Column 0 3rd Column 0 4th Column sigma 4 squared EndMatrix
Unstructured
Correlations
UNR Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 1 sigma 2 rho 21 3rd Column sigma 1 sigma 3 rho 31 4th Column sigma 1 sigma 4 rho 41 2nd Row 1st Column sigma 2 sigma 1 rho 21 2nd Column sigma 2 squared 3rd Column sigma 2 sigma 3 rho 32 4th Column sigma 2 sigma 4 rho 42 3rd Row 1st Column sigma 3 sigma 1 rho 31 2nd Column sigma 3 sigma 2 rho 32 3rd Column sigma 3 squared 4th Column sigma 3 sigma 4 rho 43 4th Row 1st Column sigma 4 sigma 1 rho 41 2nd Column sigma 4 sigma 2 rho 42 3rd Column sigma 4 sigma 3 rho 43 4th Column sigma 4 squared EndMatrix
Toeplitz TOEP Start 4 By 4 Matrix 1st Row 1st Column sigma squared 2nd Column sigma 1 3rd Column sigma 2 4th Column sigma 3 2nd Row 1st Column sigma 1 2nd Column sigma squared 3rd Column sigma 1 4th Column sigma 2 3rd Row 1st Column sigma 2 2nd Column sigma 1 3rd Column sigma squared 4th Column sigma 1 4th Row 1st Column sigma 3 2nd Column sigma 2 3rd Column sigma 1 4th Column sigma squared EndMatrix
Toeplitz with
Two Bands
TOEP(2) Start 4 By 4 Matrix 1st Row 1st Column sigma squared 2nd Column sigma 1 3rd Column 0 4th Column 0 2nd Row 1st Column sigma 1 2nd Column sigma squared 3rd Column sigma 1 4th Column 0 3rd Row 1st Column 0 2nd Column sigma 1 3rd Column sigma squared 4th Column sigma 1 4th Row 1st Column 0 2nd Column 0 3rd Column sigma 1 4th Column sigma squared EndMatrix
Heterogeneous
Toeplitz
TOEPH Start 4 By 4 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 1 sigma 2 rho 1 3rd Column sigma 1 sigma 3 rho 2 4th Column sigma 1 sigma 4 rho 3 2nd Row 1st Column sigma 2 sigma 1 rho 1 2nd Column sigma 2 squared 3rd Column sigma 2 sigma 3 rho 1 4th Column sigma 2 sigma 4 rho 2 3rd Row 1st Column sigma 3 sigma 1 rho 2 2nd Column sigma 3 sigma 2 rho 1 3rd Column sigma 3 squared 4th Column sigma 3 sigma 4 rho 1 4th Row 1st Column sigma 4 sigma 1 rho 3 2nd Column sigma 4 sigma 2 rho 2 3rd Column sigma 4 sigma 3 rho 1 4th Column sigma 4 squared EndMatrix
Spatial
Power
SP(POW)(c-list) sigma squared Start 4 By 4 Matrix 1st Row 1st Column 1 2nd Column rho Superscript d 12 3rd Column rho Superscript d 13 4th Column rho Superscript d 14 2nd Row 1st Column rho Superscript d 21 2nd Column 1 3rd Column rho Superscript d 23 4th Column rho Superscript d 24 3rd Row 1st Column rho Superscript d 31 2nd Column rho Superscript d 32 3rd Column 1 4th Column rho Superscript d 34 4th Row 1st Column rho Superscript d 41 2nd Column rho Superscript d 42 3rd Column rho Superscript d 43 4th Column 1 EndMatrix
First-Order
Autoregressive
Moving-Average
ARMA(1,1) sigma squared Start 4 By 4 Matrix 1st Row 1st Column 1 2nd Column gamma 3rd Column gamma rho 4th Column gamma rho squared 2nd Row 1st Column gamma 2nd Column 1 3rd Column gamma 4th Column gamma rho 3rd Row 1st Column gamma rho 2nd Column gamma 3rd Column 1 4th Column gamma 4th Row 1st Column gamma rho squared 2nd Column gamma rho 3rd Column gamma 4th Column 1 EndMatrix
First-Order
Factor
Analytic
FA(1) Start 4 By 4 Matrix 1st Row 1st Column lamda 1 squared plus d 1 2nd Column lamda 1 lamda 2 3rd Column lamda 1 lamda 3 4th Column lamda 1 lamda 4 2nd Row 1st Column lamda 2 lamda 1 2nd Column lamda 2 squared plus d 2 3rd Column lamda 2 lamda 3 4th Column lamda 2 lamda 4 3rd Row 1st Column lamda 3 lamda 1 2nd Column lamda 3 lamda 2 3rd Column lamda 3 squared plus d 3 4th Column lamda 3 lamda 4 4th Row 1st Column lamda 4 lamda 1 2nd Column lamda 4 lamda 2 3rd Column lamda 4 lamda 3 4th Column lamda 4 squared plus d 4 EndMatrix
Huynh-Feldt HF Start 3 By 3 Matrix 1st Row 1st Column sigma 1 squared 2nd Column StartFraction sigma 1 squared plus sigma 2 squared Over 2 EndFraction minus lamda 3rd Column StartFraction sigma 1 squared plus sigma 3 squared Over 2 EndFraction minus lamda 2nd Row 1st Column StartFraction sigma 2 squared plus sigma 1 squared Over 2 EndFraction minus lamda 2nd Column sigma 2 squared 3rd Column StartFraction sigma 2 squared plus sigma 3 squared Over 2 EndFraction minus lamda 3rd Row 1st Column StartFraction sigma 3 squared plus sigma 1 squared Over 2 EndFraction minus lamda 2nd Column StartFraction sigma 3 squared plus sigma 2 squared Over 2 EndFraction minus lamda 3rd Column sigma 3 squared EndMatrix
First-Order
Ante-dependence
ANTE(1) Start 3 By 3 Matrix 1st Row 1st Column sigma 1 squared 2nd Column sigma 1 sigma 2 rho 1 3rd Column sigma 1 sigma 3 rho 1 rho 2 2nd Row 1st Column sigma 2 sigma 1 rho 1 2nd Column sigma 2 squared 3rd Column sigma 2 sigma 3 rho 2 3rd Row 1st Column sigma 3 sigma 1 rho 2 rho 1 2nd Column sigma 3 sigma 2 rho 2 3rd Column sigma 3 squared EndMatrix


V<=value-list>

requests that blocks of the estimated marginal variance-covariance matrix bold upper V left-parenthesis ModifyingAbove bold-italic theta With caret right-parenthesis be displayed in generalized linear mixed models. This matrix is based on the last linearization as described in the section The Pseudo-model. You can use the value-list to select the subjects for which the matrix is displayed. If value-list is not specified, the bold upper V matrix for the first subject is chosen.

Note that the value-list refers to subjects as the processing units in the "Dimensions" table. For example, the following statements request that the estimated marginal variance matrix for the second subject be displayed:

proc glimmix;
   class A B;
   model y = B;
   random int / subject=A;
   random int / subject=A*B v=2;
run;

The subject effect for processing in this case is the A effect, because it is contained in the A*B interaction. If there is only a single subject as per the "Dimensions" table, then the V option displays an left-parenthesis n times n right-parenthesis matrix.

See the section Processing by Subjects for how the GLIMMIX procedure determines the number of subjects in the "Dimensions" table.

The GLIMMIX procedure displays blanks for values that are 0.

VC<=value-list>

displays the lower-triangular Cholesky root of the blocks of the estimated bold upper V left-parenthesis ModifyingAbove bold-italic theta With caret right-parenthesis matrix. See the V option for the specification of value-list.

VCI<=value-list>

displays the inverse Cholesky root of the blocks of the estimated bold upper V left-parenthesis ModifyingAbove bold-italic theta With caret right-parenthesis matrix. See the V option for the specification of value-list.

VCORR<=value-list>

displays the correlation matrix corresponding to the blocks of the estimated bold upper V left-parenthesis ModifyingAbove bold-italic theta With caret right-parenthesis matrix. See the V option for the specification of value-list.

VI<=value-list>

displays the inverse of the blocks of the estimated bold upper V left-parenthesis ModifyingAbove bold-italic theta With caret right-parenthesis matrix. See the V option for the specification of value-list.

WEIGHT<=variable>
WT<=variable>

specifies a variable to be used as the weight for the units at the current level in a weighted multilevel model. If a weight variable is not specified in the WEIGHT option, a weight of 1 is used. For details on the use of weights in multilevel models, see the section Pseudo-likelihood Estimation for Weighted Multilevel Models.

Last updated: December 09, 2022