I am analyzing data from a factorial experiment using PROC GLIMMIX in SAS. In the model, "Trt_Amend_App" is a categorical variable that is one of the experimental treatments and "ID_S" is one of two locations. The model results indicate that there is a significant interaction between Trt_Amend_App and ID_S such that Trt_Amend_App is significant at one location, but not the other. I would like to conduct a post-hoc test to determine which levels of Trt_Amend_App are different from each other, corrected for multiple comparisons using the Tukey adjustment, but only for the significant location "Site 2". How might I code that? I've included the code for my model below. The commented line under the first LSMEANS statement can be thought of a pseudocode indication of what I want to do (it doesn't work 🙂).
proc glimmix data=df_y3_t3 plots=studentpanel;
class ID_S Block Trt_Amend_App Trt_CC;
model Response_Var = Trt_Amend_App | Trt_CC | ID_S ID_S(Block);
lsmeans ID_S * Trt_Amend_App / slice=ID_S plot=meanplot(sliceby=Trt_Amend_App join);
/*lsmeans Trt_Amend_App / diff adjust=tukey where(ID_S='Site 2');*/
run;
I understand that the WHERE statement can be used to achieve the desired test in a separate procedure, but I'm hoping for a more streamlined solution. Thanks for reading.
Thanks for the suggestion, but I don't see any additional output when I add the statement.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.