Another method is to use PROC MEANS:
proc means data=luks noprint;
class Veld Sex Month Age;
var BCS;
output out=rawmeans mean=mean std=sd n=n;
run;
In the dataset rawmeans, the following _type_ variables identify the raw means that correspond to the lsmeans in your PROC MIXED (plus as a bonus, the overall mean for BCS).
_type_=0 Overall mean
_type_=1 Mean of each level of age
_type_=2 Mean of each level of month
_type_=4 Mean of each level of sex
_type_=8 Mean of each level of veld
_type_=10 Mean of each level of veld*month
So now these are available for output or for merging against the lsmeans dataset (which you could get with an ODS statement with PROC MIXED).
SteveDenham
... View more