Load the sample data.

The table `between`

includes the between-subject
variables age, IQ, group, gender, and eight repeated measures *y*1
through *y*8 as responses. The table `within`

includes
the within-subject variables *w*1 and *w*2.
This is simulated data.

Fit a repeated measures model, where the repeated measures *y*1
through *y*8 are the responses, and age, IQ, group,
gender, and the group-gender interaction are the predictor variables.
Also specify the within-subject design matrix.

Test that the coefficients of all terms in the between-subjects
model are the same for the first and last repeated measurement variable.

ans =
Statistic Value F RSquare df1 df2 pValue
_________ _______ ______ _______ ___ ___ _______
Pillai 0.3355 1.3884 0.3355 8 22 0.25567
Wilks 0.6645 1.3884 0.3355 8 22 0.25567
Hotelling 0.50488 1.3884 0.3355 8 22 0.25567
Roy 0.50488 1.3884 0.3355 8 22 0.25567

The *p*-value of 0.25567 indicates that there
is not enough statistical evidence to conclude that the coefficients
of all terms in the between-subjects model for the first and last
repeated measures variable are different.