= Solution
The violated assumption is <independence of random variables> across observations: repeated measurements on the same rat form <clustered data>. A persistent rat-specific weight difference induces positive within-rat <covariance>, even after adjustment for time and diet. Treating all 176 measurements as independent is <pseudoreplication>.
For the claimed lack of <identifiability> in the second fit, Rat must be a <categorical variable>, as intended by the rat-effect interpretation. Each rat receives only one diet, so this is <confounding of nested fixed factors>. If $z_r$ is the rat-indicator column, the diet-$d$ indicator is $\sum_{r:\,D_r=d}z_r$. Thus a diet effect can be increased by $c_d$ and every corresponding rat effect decreased by $c_d$, leaving all <fitted values> unchanged. With an intercept, two diet columns, fifteen rat contrasts and time, there are 19 columns but only 17 independent columns: the intercept and rat contrasts already span the diet columns, while time varies within rats. This gives <rank-deficient ordinary least squares>.
\b[The first model ignores within-rat dependence; the second cannot separate unrestricted fixed diet and rat effects.] If Rat were instead encoded as a single numeric predictor, the asserted rank deficiency would not follow merely from nesting.
Back to article page