Hi all,
I have data collected across 4 sites and would like to perform a test to
see whether the relationship between 2 binary variables, say A and B,
differs between the sites.
I think it makes sense to treat the sites as a random sample of sites, and
thus use a random coefficient model with both random slope and intercept.
Test would then be via a likelihood ratio test with the nested random
intercept model (without the random slope).
1st. My question is: Is this all good?
Secondly, however, in one of the sites, the dependent variable (B) has
only one value. So in normal (fixed-effects) logistic regression, this
would be impossible due to the presence of empty cells. (In other words
for both levels in A, the outcomes in B are entirely 0 in this particular
site).
Modelling using random slopes and intercepts won't give me an error
message, but I wonder if the output is still valid.
For your information, my entire dataset consist of 248 observations. THe
smallest sites still have 28 observations. THe variable A has about half 0
and half 1 in all sites. THe variable B has about 85% 0 and 15% 1 in all
sites except the above.
I used gllamm in STATA for the modelling. What struck me was that for the
other sites, my unconditional log-odd-ratios (b1+u1) are (.000, .110, and
.175), but for the site with a pure B variable, STATA gives me a
log-odd-ratio of .888, considerably higher than the rest.
Any comments would be appreciated.
Thanks.
Timothy Mak
|