Hello Statalist!
This is my first post but I've used Statalist with much success to help solve previous issues.
I am using difference in difference analysis to analyze results from a controlled before and after trial. My observations have two levels of non-independence/clustering. First, I have "before and after" (read: repeated) measures on individuals. Second, individuals are clustered by community. I would like to use GEE with family(poisson) and link(log) and robust standard errors to obtain risk ratios. However, I am having some trouble accounting for multiple layers of clustering using GEE.
My first though was to use the participant identifier (participantid) as the panel variable and then use vce(cluster clustervar) to account for clustering by community. However, when I ran the following code, I received the below error:
xtset participiantID
xtgee outcome phase studyarm phase*studyarm, family(poisson) link(log) vce(cluster communityID) robust eform
options vce() and robust may not be combined
r(198);
So, I have a couple of questions and a request:
1. Is the "robust" at the end of the code redundant since I'm including vce(cluster communityID)? If not, does anyone know a work-around?
2. If anyone has experience running multi-level GEE in Stata and has a better approach, I would be very happy to discuss and try it!
Thanks in advance for any help you can provide.
This is my first post but I've used Statalist with much success to help solve previous issues.
I am using difference in difference analysis to analyze results from a controlled before and after trial. My observations have two levels of non-independence/clustering. First, I have "before and after" (read: repeated) measures on individuals. Second, individuals are clustered by community. I would like to use GEE with family(poisson) and link(log) and robust standard errors to obtain risk ratios. However, I am having some trouble accounting for multiple layers of clustering using GEE.
My first though was to use the participant identifier (participantid) as the panel variable and then use vce(cluster clustervar) to account for clustering by community. However, when I ran the following code, I received the below error:
xtset participiantID
xtgee outcome phase studyarm phase*studyarm, family(poisson) link(log) vce(cluster communityID) robust eform
options vce() and robust may not be combined
r(198);
So, I have a couple of questions and a request:
1. Is the "robust" at the end of the code redundant since I'm including vce(cluster communityID)? If not, does anyone know a work-around?
2. If anyone has experience running multi-level GEE in Stata and has a better approach, I would be very happy to discuss and try it!
Thanks in advance for any help you can provide.
Comment