Hi - I have a dataset on cattle where we captured the amount of time each animal ate food (in minutes). We have several class effects to include (breed, size, year of study, and day relative to estrus). Running this model in PROC MIXED "as is" suggests the residuals are not normally distributed. Comparing square root and log transformations in PROC MIXED suggest that square root transformation is a better option. When I run the exact same model in PROC GLIMMIX so I can get inverse link means and standard errors, the outcomes are not the same (with or without nloptions in code provided). PROC GLIMMIX almost looks like PROC MIXED when the variable was not transformed. I'm not sure why and I am hoping experts here can help explain. I've attached SAS output of these scenarios to demonstrate. Code used includes: *TIME, Min - no transformation;
proc mixed data= nobullestrusC plots = all;
class HeiferID Breed FSGrp Year DRE;
model TimeMin = Year Date Breed|DRE FSGrp|DRE / ddfm=kr;
repeated DRE / subject=HeiferID type=csh;
run;
*TIME, Min - log function transformed;
proc mixed data= nobullestrusC plots = all;
class HeiferID Breed FSGrp Year DRE;
model logTmin = Year Date Breed|DRE FSGrp|DRE / ddfm=kr;
repeated DRE / subject=HeiferID type=csh;
run;
*TIME, Min - square root function transformed;
proc mixed data= nobullestrusC plots = all;
class HeiferID Breed FSGrp Year DRE;
model sqrtTmin = Year Date Breed|DRE FSGrp|DRE / ddfm=kr;
repeated DRE / subject=HeiferID type=csh;
run;
*Time, Min - square root transformation in glimmix;
proc glimmix data = nobullestrusC plots=all;
nloptions technique = NRRIDG;
class HeiferID Breed FSGrp Year DRE;
model TimeMin = Year Date Breed|DRE FSGrp|DRE / ddfm=kr link = power(0.5);
random DRE / subject = HeiferID type = CSH residual;
run; I'll also note that the covariance structure type was limited going across procedures, but CSH was the best fit of ones that worked across both. Thank you for help here!
... View more