As to checking whether results are equivalent, you don't have to do 5 variables - just any number more than 2. I don't know, maybe 3? You could then explicitly check your conjecture, using the syntax you suggested.
But ..., the phrase "nested in the preceding variable [note singular case] in the ABSORB statement" taken literally, would suggest that
proc glm;
absorb herd cow staff;
model y=a b a*b;
run;
is NOT equivalent to
proc glm;
class herd cow staff a b;
model y=herd cow(herd) staff(herd) staff(cow) a b a*b;
run;
I would interpret the text of the quoted documentation to mean the equivalent would be:
proc glm;
class herd cow staff a b;
model y=herd cow(herd) staff(cow) a b a*b;
run;
although this disturbs me, since I don't see how it accommodates staff*herd interaction (which your suggestion does), nor herd*staff*cow.
Perhaps the absorb herd cow staff; statement is really equivalent to
proc glm;
class herd cow staff a b;
model y=herd cow*herd staff*cow*herd a b a*b;
run;
This latter model doesn't ask for estimates of the main effects of cow or staff, nor the cow*staff or herd*staff interactions. But they are essentially nuisance parameters for your purposes. I think the cow main effect would be "absorbed" in the specified cow*herd estimate. Similarly the staff main effect, the staff*cow interaction, and the staff*herd interaction would all be absorbed in the staff*cow*herd interaction. However, this is just speculation on my part, but testable. If I'm right, though, then the equivalent for absorbing 5 variables (call them M, N, O, P, and Q) would be:
proc glm;
class M N O P Q A B;
model y= M N*M O*N*M P*O*N*M Q*P*O*N*M A B A*B;
run;
I would appreciate comments from any of our experienced statistics practitioners.
... View more