Hi All,
I would like to look at whether arrival age (ageA), arrival weight (wta) and age at first calving (AFF) have an effect on calving rate (FR1); each of the above factors are grouped for example ageA is, 22-24 months, 24-26 months and 26-28months.
The ultimate outcome is to be able to use the above factors as predictive measures for calving rate. Below is the analysis I have run:
Only AFF is significant, the others are not and the LSmeans are producing the below;
What does non-est mean? does this indicate that this analysis is inappropriate for this data? Is there a more suitable option?
Cheers
I would treat the ages and weight as continuous rather than category (CLASS) variables.
Non-est happens when you don't have at least one observation in each cell of the tables AFF*ageA and AFF*wta. So your model is inappropriate with the data you have. GLM is not the problem.
Thankyou for your reply.
I checked the data and there were some missing observations that I have now corrected, but this did not make a difference. I then changed the ageA and wta to continuous rather than category, but again it still returns non-est.
@EM_G wrote:
Thankyou for your reply.
I checked the data and there were some missing observations that I have now corrected, but this did not make a difference. I then changed the ageA and wta to continuous rather than category, but again it still returns non-est.
Unlike other commenters here, I believe your problem is due to missing cells in the interaction of two variables.
I don't know what you mean by "missing observations". I was talking about missing cells in the interaction table, combinations of levels of two variables where there are no observations.
Often it means that one of the class variables is a linear combination of other variables. There is redundant information in the explanatory variables. For example, the following data step intentionally creates a classification variable C2 that is related to C1. The LSMEANS statement will return "Non-est" instead of a value:
data Have;
do c1 = 1,2;
c2 = 2*c1; /* linear combination of other class variables */
do c3 = 1 to 5;
x = rand("normal");
output;
end;
end;
run;
proc glm data=Have;
class c1 c2 c3;
model x = c1 c2 c3 c3*c1 c3*c2;
lsmeans c1 c2 c3 c3*c1 c3*c2 / stderr;
run;
For your data, it is possible that arrival age (ageA) and age at first calving (AFF) are related. For example, AFF = ageA + 2.
Thank you for your reply.
You are correct that ageA and AFF are related. Is there a way to get my model to work around this? sorry I am very new to stats and sas. I have just finished reading sas/stat user guide version 8 chapter 30 on GLM procedure, but still haven't found my answer.
Cheers Em
If ageA and AFF are completely confounded (as in @Rick_SAS 's example) where you can express one as a linear function of the other, then the easiest thing to do is to remove one of them as a model effect. For example:
proc glm data=par1;
class ageA wta;
model FR1 = ageA wta ageA*wta;
lsmeans ageA wta /pdiff;
lsmeans ageA*wta / slice= (ageA wta);
quit;
run;
This will give comparisons between the levels of ageA as well as comparisons between the levels of wta. The lsmeans statement for the interaction uses the SLICE= option to obtain F tests for the simple effects of wta at each level of ageA and of ageA at each level of wta. If you want specific comparisons of the lsmeans at each level, you'll need to employ the STORE option to get the SLICE statement. Note that now there is only one age related effect, so the overall F tests will not separate out a test for age at first calving. However, that shouldn't be an issue if age at first calving is a simple additive function of age at arrival.
SteveDenham
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
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.