SAS Syntax - Keyword Repeated

REPEATED = FactorName;

REPEATED = FactorName Levels FactorName Levels;

Example
REPEATED = TIME 3 DIALS 3;

Optional keyword; specify the names and number of levels for the repeated measures factors; if only one repeated measures factor is specified, the number of dependent variables from the MODEL statement will be taken as the number of levels for that repeated measures factor. Note that, unlike SAS, GLM supports double-multivariate designs, i.e., designs with repeated measures factors and multiple dependent variables (measures).

Assignment of dependent variables to levels of the repeated measures factors
Consecutive variables in the dependent variable list (specified via the MODEL keyword) are assigned to the levels of the repeated measures factors. Let p be the product of the levels of all repeated measures factors defined with the REPEATED keyword. In the example shown above, p would be equal to 3*3 = 9. Divide the number of dependent variables m by p to determine the number of dependent measures; if (n, p) is not equal to 0 (i.e., m/p is not an integer value greater or equal to 1), an error message will be issued. To assign the consecutive dependent variables to the levels of the repeated measures factors, the program will cycle through a nested loop, where the number of dependent measures has the fastest moving subscript, the last specified repeated measures factor the next-to-fastest moving subscript, the next-to-last specified repeated measures factor has the next slower moving subscript, and so on.

For example, suppose the dependent variable list consisted of variables DV1, DV2, DV3, DV4, DV5, DV6, DV7, DV8, and the REPEATED measures of R1 with 2 levels, and R2 with 2 levels. The assignment of dependent variables to the levels of the repeated measures factors will then proceed as follows:

DV Level for R1 Level for R2 Dependent Measure
DV1 1 1 1
DV2 1 1 2
DV3 1 2 1
DV4 1 2 2
DV5 2 1 1
DV6 2 1 2
DV7 2 2 1
DV8 2 2 2

Applies to. GLM (SAS syntax is only available for GLM)