Announcement

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

  • Interaction in logistic regression.

    Hello everybody.

    I have done logistic regression using the DV ( dependent variable) and IV (independent variable). But what happens when I use more than this two variables? and when I used this command ## between the variables? I supposed this means interaction, but... how can I interpreted?

    Thanks!

    Veronica Guzman.

  • #2
    Veronica. Take a look at the thread at http://www.statalist.org/forums/foru...atory-variable, especially #2 and #3. The situation there is actually more complicated than yours, because that poster asks about -ologit-, which has multiple outcome levels instead of just two. But the same general reasoning about the interpretation of interactions applies.

    Comment


    • #3
      I have a question about the interaction term, too. So I hope dear Statalist, it is ok, if I ask it here. How is it possible to see whether an Interaction term makes sense in a model? Maybe with a tabulate x1 with x2 (independent variables) and look whether the row percecntage (or column percentage) is above 50%?

      And doing xi: logit y i.x1 i.x2*i.x3 is similar to xi:logit y i.x1 x2##x3 ?

      Comment


      • #4
        And doing xi: logit y i.x1 i.x2*i.x3 is similar to xi:logit y i.x1 x2##x3
        Unless you are using an earlier version of Stata that does not support factor variables, or one of the handful of very old modeling commands that does not support factor variables even in Stata 14, you should stop using the xi: prefix. The results of the regressions will be the same either way, but you cannot use -margins- correctly after -xi:...-; the regression output is not nearly as well organized; and there is no straightforward way to create 3-way (or higher) interactions with xi:.

        The easiest way to understand the results of a model with an interaction like this is to look at the output of -margins x2#x3-: it shows you the predicted probabilities (adjusted for x1) in each combination of x2 and x3.

        Doing a tabulation of x1 with x2 will show you the frequencies with which each of those combinations occurs, but it says nothing about the role of the interaction effect in the logistic model. Creating a table with values of x1 in the stubs, x2 in the column heads, and the mean values of your outcome variable in the cells will give you a very rough idea of what the interaction does--but it will fail to adjust for x1, and in multi-level models the results can be seriously misleading if the distributions of the higher-level variables differ according to the values of x1 or x2 (or both). So I don't recommend that approach.

        Comment


        • #5
          Thanks a lot, Sir!! I am using Stata 13 which supports factor variables. I have read in the book "Logistic Regression Models by Joseph M. Hilbe" that there is a possibility to see whether two categorical variable interact which can be done with xi3 and postgr3. Now I have read that this is no longer supported. Do you thing vibl is a good alternative?

          Comment


          • #6
            I am not familiar with -vibl-, so I can't comment on it. But why don't you just use factor notation and -margins- as I have suggested? What are you looking for that that doesn't give you? If you are looking to literally "see" the interaction in a graph, you can run -marginsplot- immediately after -margins-.

            Comment


            • #7
              Ok, thank you very much, Sir! Because I am writing my thesis with just interpreting the logit coefficients, so I thought that I should use vible instead of margins.m But I will try it with margins and marginsplot.
              Last edited by Anshul Anand; 02 Jun 2015, 10:59.

              Comment


              • #8
                You can interpret the results without refering to margins, see: http://www.stata-journal.com/article.html?article=st0194
                ---------------------------------
                Maarten L. Buis
                University of Konstanz
                Department of history and sociology
                box 40
                78457 Konstanz
                Germany
                http://www.maartenbuis.nl
                ---------------------------------

                Comment


                • #9
                  Thanks for the article!

                  Comment

                  Working...
                  X