Hi, I am trying to use the estimate statement to make between-subject comparisions. I have managed to do so with the first estimate statement for the time, but I am unable to do so for the groups. I am getting the error "WARNING: More coefficients than levels specified for effect Group. Some coefficients will be ignored.". The code I am using is below, the part in bold is getting the error. Thank you.
proc mixed data=work.all;
class group ID time;
model HSP27=group time group*time time0 /cl;
repeated time/subject=ID(group) r rcorr type=vc;
ods output covparms=cov rcorr=corr;
estimate 'time2-time4' time 1 - 1 0 0 0 0 0 0 group*time 1 - 1 0 0 0 0 0 0;
estimate 'time2-time6' time 1 0 - 1 0 0 0 0 0 group*time 1 0 - 1 0 0 0 0 0;
estimate 'time2-time8' time 1 0 0 - 1 0 0 0 0 group*time 1 0 0 - 1 0 0 0 0;
estimate 'time2-time10' time 1 0 0 0 - 1 0 0 0 group*time 1 0 0 0 - 1 0 0 0;
estimate 'time2-time12' time 1 0 0 0 0 - 1 0 0 group*time 1 0 0 0 0 - 1 0 0;
estimate 'time2-time14' time 1 0 0 0 0 0 - 1 0 group*time 1 0 0 0 0 0 - 1 0;
estimate 'time2-time16' time 1 0 0 0 0 0 0 - 1 group*time 1 0 0 0 0 0 0 - 1;
estimate 'Control-HSP27 t2' group 1 - 1 0 group*time 1 - 1 0 0 0 0 0 0 0;
estimate 'Control-HSP27 t4' group 1 - 1 0 group*time 1 0 - 1 0 0 0 0 0 0;
estimate 'Control-HSP27 t6' group 1 - 1 0 group*time 1 0 0 - 1 0 0 0 0 0;
estimate 'Control-HSP27 t8' group 1 - 1 0 group*time 1 0 0 0 - 1 0 0 0 0;
estimate 'Control-HSP27 t10' group 1 - 1 0 group*time 1 0 0 0 0 - 1 0 0 0;
estimate 'Control-HSP27 t12' group 1 - 1 0 group*time 1 0 0 0 0 0 - 1 0 0;
estimate 'Control-HSP27 t14' group 1 - 1 0 group*time 1 0 0 0 0 0 0 - 1 0;
estimate 'Control-HSP27 t16' group 1 - 1 0 group*time 1 0 0 0 0 0 0 0 - 1;
run;
You have 9 coefficients for group*time.
This is a really good time to look at the documentation for the LSMESTIMATE statement, and at the nonpositional syntax method of coding estimates, contrasts and lsmestimates.
Steve Denham
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.