Announcement

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

  • Multinomial logistic regression between continuous independent variable quartiles keeping one of them as reference

    Hello,
    I am unable to figure out how to run a multinomial regression analysis on a categorical dependent variable with a continuous independent variable which has been split into quartiles. And i wish to run this regression keeping quartile 1 as a base/referent group in stata.
    Any guidance for this would be very much appreciated.
    Thank You
    Chitresh

  • #2
    Welcome to the forum.
    The example below show the base steps. You should read the help fvvarlist in order to understand Stata notation of continuous and categorical variables.

    Code:
    sysuse auto, clear
    // generating quartiles from continuous variable
    egen price_group=cut(price), group(4)
    // check groups range
    table price_group, c(min price max price n price)
    // read the help file
    help fvvarlist
    //multinomial regression with categorical variable with the lowest value as the reference
    
    mlogit rep78 ib0.price_group, b(5)

    Comment


    • #3
      Wow, that's the fastest help i have ever received on any forum. Thank you, Sir. That helped a lot.

      Comment


      • #4
        Originally posted by Oded Mcdossi View Post
        Welcome to the forum.
        The example below show the base steps. You should read the help fvvarlist in order to understand Stata notation of continuous and categorical variables.

        Code:
        sysuse auto, clear
        // generating quartiles from continuous variable
        egen price_group=cut(price), group(4)
        // check groups range
        table price_group, c(min price max price n price)
        // read the help file
        help fvvarlist
        //multinomial regression with categorical variable with the lowest value as the reference
        
        mlogit rep78 ib0.price_group, b(5)

        Need to ask one more thing...
        i am running multinomial logistic regression between serum levels of prolactin & three states of blood glucose regulation i.e normal(1), impaired, diabetic.
        so my command reads:
        mlogit glucoseregulation ib0.prolactin_group, b(1)
        now how do i adjust results for covariate such as age so as to calculate result of multinomial logistic regression but this time age adjusted...

        Comment


        • #5
          Chitresh:
          if you want to consider -age- as a continuous variable (i.e., not divided into quartiles, other quantiles or whatever categories), you may want to try:
          Code:
          mlogit glucoseregulation c.age ib0.prolactin_group, b(1)
          Kind regards,
          Carlo
          (Stata 19.0)

          Comment


          • #6
            Sorry Carlo, but i didn't get it... just adding c.age in the prior command generates coefficients for GlucoseRegulation vs Age. Could you please elaborate on how to multivariate adjust those mlogit results?

            Comment


            • #7
              Chitesh:
              I repost my idea elaborating on the last line of Oded's helpful code (the continuous variable is -length- in this instance):
              Code:
              mlogit rep78 c.length ib0.price_group, b(5)
              Kind regards,
              Carlo
              (Stata 19.0)

              Comment


              • #8
                Sadia:
                welcome to this forum.
                In order to increase your chances of getting helpful replies, you're kindly recommended to start a new thread. Thanks.
                Kind regards,
                Carlo
                (Stata 19.0)

                Comment

                Working...
                X