Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Cross-level interaction (random-slope multilevel logistic regression)

    Dear members of the list,

    I'm running a random slope multilevel logistic regression to assess a possible moderator effect of income inequality (country-level) on the effect of father's education on university graduation. Individual data is nested into countries, and university graduation ('univ') is my dependent variable

    In my model, there is a number of level-1 (L1) variables and one level-2 variable (L2). As I said before, I am particularly interested in testing if the L2 variable (Gini coefficient) moderates the effect of father's education on the probability of attaining university graduation. The variable 'cntryid6_group' identifies the country, my second level in my analysis

    This is a equivalent to a cross-level interaction (see in the following lines). I implicitly assume that the model should be specified as a model with random slopes for L1 variable, but I am not sure of the correct syntax to use. In particular, I am not sure of the need to add the R Laplacian operator before the name of the variable whose random coefficient I want to estimate.

    Option 1:
    HTML Code:
    xtmelogit univ i.edufath##c.GINI female age || cntryid6_group: edufath

    Option 2:
    HTML Code:
    xtmelogit univ i.edufath##c.GINI female age || cntryid6_group: R.edufath
    I have searched hard for information but I have not got a clear idea answer to my doubt. When is it appropriate to introduce this R Laplacian operator before the variable whose random-coefficient is estimated?. In my case, this variable is 'edufath', which is a categorical one (three categories) and captures father's education.

    Thanks a lot for your attention and your help

    Kind regards

    Luis Ortiz
    Last edited by Luis Ortiz; 09 Jul 2021, 09:40.

  • #2
    Well, you don't actually need to answer that question, because the code you show does not model the interaction you are interested in.

    You are being confused by the terminology "cross-level interaction." The interaction between Gini and father's education is not a cross level interaction even though the two variables are defined at different levels. The term cross-level interaction has two meanings, one of which corresponds to a random slope model, and the other does not. The one that involves a random slope in the model refers to an interaction between an observed variable and the (latent) random intercept for another level. The code you show, with or without an R. refers to a model in which the effect of edufath would be modified by cntryid6_group itself (not simply by some other variable that happens to be defined at the cntryid6_group level). The type of interaction you have described, however, does not involve an effect modification by cntryid6_group itself, but just by the observed variable GINI. So the code you need involves no random slope. It should be:

    Code:
    melogit univ i.edufath##c.GINI female age || cntryid6_group:
    Note: I changed -xtmelogit- to -melogit- because the name of the command was changed a few versions back to -meqrlogit-, which was then combined with -melogit- into a single, unified, -melogit- command that is used today. Modern Stata will still recognize -xtmelogit- as a valid command name, but will run -melogit-.

    Comment


    • #3
      Many thanks for your answer, Clyde

      I clearly got it wrong, or I did not express mysefl very clearly.

      I'm slightly confused. I do apologise for asking again....; I hope you don't mind.

      I thought that any interaction between a L1 variable and a L2 variable implied that the slope of the variable at the lower level L1 varies (it is not fixed) In other words, I thought that such an interaction should always be integrated in a random-slope multilevel model. I drew this idea from readings like the ones that I cite next, but I possibly got them wrong too.

      Aguinis et al. (2013) 'Best-Practice Recommendations for Estimating Cross-Level Interaction Effects Using Multilevel Modelling', Journal of Management 39(6): 1490-1528

      Heisig, J. P., & Schaeffer, M. (2019). 'Why you should always include a random slope for the lower-level variable involved in a cross-level interaction'. European Sociological Review, 35(2), 258-279.

      In the code that you're suggesting, there's no random slope of father's education. Could interactions between two levels in a multilevel regression being modelled like that?

      My apologies for the confusion, and many thanks for your attention again

      Best

      Luis Ortiz

      Comment


      • #4
        I thought that any interaction between a L1 variable and a L2 variable implied that the slope of the variable at the lower level L1 varies (it is not fixed)
        Yes, and this is also true of interactions between variables at the same level. It is, in fact, the definition of an interaction.

        In other words, I thought that such an interaction should always be integrated in a random-slope multilevel model.
        No. When it is a specific L2 variable that modifies the effect of the L1 variable, there is no need for a random slope. You just put in the interaction term the same way you would between two L1 variables.

        In the code that you're suggesting, there's no random slope of father's education. Could interactions between two levels in a multilevel regression being modelled like that?
        That's right, no random slope of father's education is called for here. You have not described anything that calls for it: you have not suggested that the effect of father's education varies by cntryid6_group other than by virtue of the GINI coefficient which is defined at that higher level. The GINI coefficient, as you have described it, is the only L2 source of modification of the effect of father's education. So just having i.edufath##c.GINI fully captures that. To include a random slope for edufath would be to state that in addition to the specific effect modification attributable to GINI, there is additional variation in the effect of fathedu that is attributable to unobserved L2 factors.

        Now, there may well be such additional effect modification in reality--and if that is the case, you should have a random slope for fathedu. But that is different from what you described in #1. If you believe that GINI accounts for all modification of the fathedu effect from L2, then you should not include a random slope. The model should reflect what you believe is (closest to) the real data generating process.

        I'm not familiar with the Aguinas et al. reference, and the link you provided only gives me the abstract. I do not have access to this journal through my institution.

        As for the Heisig & Schaffer reference, it really doesn't say anything different from what I have been saying here. What they do assert, however, that in most social science contexts a model in which all cross level effect modification is channeled through a single variable like GINI is inherently implausible. That is, they are saying that you should always assume that there is additional L2 effect modification. Fair enough--I'm not a social scientist, and I won't argue a substance question. If you agree with that, then you should a) change your description of the problem you are modeling to reflect that, and b) add a random slope for edufath. The syntax for that in the current version of Stata (17) is -|| cntryid6_group: i.fathedu-. I don't remember how it was done in version 16. Earlier than that you would have used the R. operator.
        Last edited by Clyde Schechter; 09 Jul 2021, 16:12.

        Comment


        • #5
          Thanks for such a rich and enlightening response, Clyde. It’s very helpful.

          All the best

          Luis Ortiz

          Comment

          Working...
          X