10-01-2014 10:09 AM
I am using PROC GLIMMIX to perform a multilevel logistic regression. I am interested in a number of interaction effects. Breaking down interactions for categorical*categorical terms is relatively straightforward with LSMEANS; however, I have not been able to find a resource which details how to break down custom hypotheses for continuous*categorical interaction terms. Does anyone have suggestions for resources that may detail how to explore these types of interactions for a PROC GLIMMIX logit model?
10-03-2014 02:19 PM
Do whatever it takes to get a copy of Walt Stroup's Generalized Linear Mixed Models. Then turn to page 220 where he starts a section on Analysis of Covariance. This will walk you through how to handle covariate(continuous) by treatment(categorical) interactions and specific tests at various levels of the continuous variable.
08-24-2015 08:02 AM
I'm sorry to use this section to my own interest. But I have the same question and I can not find the right command ...
This is my model on avian reproduction. Where age1 is a continuous variable(1, 2, 3) and sex is categorical (1= male, 2= female).
proc glimmix data=Reproduction INFOCRIT=PQ noreml;
class Sex nest Age2 ring;
model Reproduction (Event="1") = Sex Age1 Sex*Age1/dist= binomial link=logit solution cl;
random Age2/ subject=ring (nest) type=cs residual;
ESTIMATE 'sex 1 vs 2 at age 1 in' sex -1 1 0 Sex*Age1 -1 1 0 ;
ESTIMATE 'sex 1 vs 2 at age 2 in' sex -1 1 0 Sex*Age1 -2 2 0 ;
ESTIMATE 'sex 1 vs 2 at age 3 in' sex -1 1 0 Sex*Age1 -3 3 0 ;
Could you tell me the correct command to see estimates of the interaction "Sex*Age1"? The estimates that I have shown in my model, showed me only sex differences for each age, but I need male differences along age. I'm sorry for my limited knowledge of SAS.
Thank you very much.
All the best,
08-24-2015 11:06 AM
I'm sorry but I can not understand how this works. In my case it is an interaction between a continuous and categorical variable, and I also used proc GLIMMIX with dist= binomial link=logit. Although the method could be similar (continuous*continuous), it is difficult to understand because my little knowledge in SAS. In my particular model, what should I use?
Thank you very much,
08-24-2015 03:05 PM
I don't quite understand your question, but I think you want to know the mean difference between age1 of 1 and 3 (for example) for males. The third contrast will do this, but I show the first two so you can see the steps.
estimate 'm age 1' int 1 sex 1 0 age1 1 sex*age1 1;
estimate 'm age 3' int 1 sex 1 0 age1 3 sex*age1 3;
estimate 'm, age 3-1 ' age1 2 sex*age1 2;
Note the the last estimate is the difference between the first two (which give you means for age 1 and age 3, both for males only [the first level of sex]). WIth the difference, terms like the intercept and sex main effect cancel.
By the way, there are only two levels to your sex*age1 interaction, so your estimate statements will not work.