Dear Lucy, I would suggest the following model: proc mixed ...; class trial; * 1=pre, 2=post ; model heartbeat = drinklevel * trial ; random drinklevel / subject = patient_id; repeated / subject = patient_id type=cs; estimate 'drinklevel*trial' drinklevel * trial; run; Modelling a random effect is necessary, when the response is heterogenous between patients (maybe because of some other unknown factors). It might be also necessary to model a different covariance of data within each trial and between different trials (i.e. before and after intervention). So you could try different covariance types in the "repeated"-statement (option type), or add the option "Group", which enables to model heterogeneity in the covariance matrix (see SAS-documentation of proc mixed). Regards, Peter Regards, Peter
... View more