# Test effect of variable across sub-groups logistic regression

I have a logit model where I am predicting stunting (a binary indicator of malnutrition), and my two binary independent variables (improved.water and has.insurance) are both statistically significant:

stunting ~ improved.water + has.insurance


I want to ask the question, what is the effect of having insurance for those with improved water compared to those without improved water. One simple way to do this would be to perform the regression separately on the subgroups (with, without improved water), and see what the relationship is between having insurance and being stunted. Is there a more appropriate way to test this? I've looked into interaction effects, but am not sure how to implement them / interpret them in this context. I am using stata to do the analysis, so if the response is "use an interaction term", a more detailed explanation would be really helpful.

-
– Macro Aug 25 '12 at 15:50
It is worth noting that, in logistic regression, stratifying the data set and fitting two separate models vs. including the interaction term as described in the answer below will both give you the exact same fit. – Macro Aug 25 '12 at 16:00