Hi,
I need to plot an interaction effect in a discrete-time survival model (xtcloglog specification). I am currently doing it using margins command, in the following way:
xtcloglog dv iv m c.iv#c.mv
margins, at (iv=(min(range)max) mv=(mean-2*s.d mean+2*s.d))
marginsplot, noci recast(line) scheme(s1mono)
I have 2 questions regarding this approach:
1) Would this be a correct approach for discrete-time survival models?
2) Plots change quite significantly when reversing the iv with the mv, i.e. when I plot the following:
xtcloglog dv iv m c.iv#c.mv
margins, at (mv=(min(range)max) iv=(mean-2*s.d mean+2*s.d))
marginsplot, noci recast(line) scheme(s1mono)
I assume this is due because iv and mv differ when it comes to mean and s.d. However, I would have initially assumed them to have quite similar patterns, which is not the case in my sample. Is there a more detailed explanation of why this happens?
Any help would be much appreciated.
Thanks,
Giuseppe
I need to plot an interaction effect in a discrete-time survival model (xtcloglog specification). I am currently doing it using margins command, in the following way:
xtcloglog dv iv m c.iv#c.mv
margins, at (iv=(min(range)max) mv=(mean-2*s.d mean+2*s.d))
marginsplot, noci recast(line) scheme(s1mono)
I have 2 questions regarding this approach:
1) Would this be a correct approach for discrete-time survival models?
2) Plots change quite significantly when reversing the iv with the mv, i.e. when I plot the following:
xtcloglog dv iv m c.iv#c.mv
margins, at (mv=(min(range)max) iv=(mean-2*s.d mean+2*s.d))
marginsplot, noci recast(line) scheme(s1mono)
I assume this is due because iv and mv differ when it comes to mean and s.d. However, I would have initially assumed them to have quite similar patterns, which is not the case in my sample. Is there a more detailed explanation of why this happens?
Any help would be much appreciated.
Thanks,
Giuseppe
Comment