Announcement

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

  • error obtaining starting values; try fitting a marginal model in order to diagnose the problem

    Hi Statalist

    First time poster, long time reader here. I have searched the list and online for answers l but I haven't had any luck.

    Error message: error obtaining starting values; try fitting a marginal model in order to diagnose the problem
    r(459);

    I am running a series of xtmelogit models for my project with HILDA data. I could run every other model except this particular model. I have used the outcome variable in other models with no error messages.

    Code: xtmelogit NILF_FR i.anatsi i.helth ghpf hgage i.funds_n wealth pincomeg ghmh i.edhigh1 || xwaveid2:, var mle

    NILF_FR is a binary variable containing only 0 and 1.
    ghpf is physical functioning scale (continuous)
    hgage is age (continuous)
    wealth and pincomeg are also continuous
    ghmh is mental health scale (continuous)


    I have tried making variables like age and physical functioning a factor variable but no luck.
    I have also tried a smaller model (either just with demographics/SES, and just with mental health physical health). But it still won't run.

    I don't quite know how to fix this. The same model but xtmixed instead of xtmelogit runs ok. But I do want xtmelogit as the outcome variable is binary.

    Any thoughts/suggestions please? I don't know what I am doing wrong here.

    Thanks
    Su Mon

  • #2
    What version of Stata are you using? On Stata, when I run
    Code:
    help xtmelogit
    I am told
    xtmelogit has been renamed to meqrlogit. xtmelogit continues to work but, as of Stata 13, is no longer an official part of Stata. This is the original help file, which we will no longer update, ... .
    For that matter, a similar message is issued for xtmixed.

    On the other models that were successfully run, were any of them also run using xtmelogit, or were they run for continuous outcome variables?

    Comment


    • #3
      Originally posted by William Lisowski View Post
      What version of Stata are you using? On Stata, when I run
      Code:
      help xtmelogit
      I am told


      For that matter, a similar message is issued for xtmixed.

      On the other models that were successfully run, were any of them also run using xtmelogit, or were they run for continuous outcome variables?
      Hi William. I am using Stata 17 MP. I don't get this error for other xtmelogit models so I am pretty sure it's not an issue with changing to meqrlogit. If so, I should get an error for that for my other models. It is definitely something else. I did try meqrlogit but that did not help. I am getting the same error.

      Comment


      • #4
        Originally posted by Su Mon Kyaw-Myint View Post
        Error message: error obtaining starting values; try fitting a marginal model in order to diagnose the problem
        r(459);

        I have tried making variables like age and physical functioning a factor variable but no luck.
        I have also tried a smaller model (either just with demographics/SES, and just with mental health physical health). But it still won't run.

        I don't quite know how to fix this. . . .

        Any thoughts/suggestions please?
        Originally posted by Su Mon Kyaw-Myint View Post
        I did try meqrlogit but that did not help. I am getting the same error.
        But have you tried "fitting a marginal model in order to diagnose the problem"?

        Comment


        • #5
          Originally posted by Joseph Coveney View Post

          But have you tried "fitting a marginal model in order to diagnose the problem"?
          That could be my problem. English is my second language and I don't quite understand what " try fitting a marginal model means"? Can you explain it to me please? It would be a huge help.

          Comment


          • #6
            Originally posted by Su Mon Kyaw-Myint View Post
            English is my second language and I don't quite understand what " try fitting a marginal model means"? Can you explain it to me please? It would be a huge help.
            Oh, sorry, sure. It would be something like the following.
            Code:
            logit NILF_FR i.(anatsi helth funds_n edhigh1) c.(ghpf hgage wealth pincomeg ghmh)
            
            // optionally
            logit NILF_FR i.(anatsi helth funds_n edhigh1) c.(ghpf hgage wealth pincomeg ghmh), vce(cluster xwaveid2)
            
            // or
            xtgee NILF_FR i.(anatsi helth funds_n edhigh1) c.(ghpf hgage wealth pincomeg ghmh), i(xwaveid2) family(binomial) link(logit) // various other options
            I recommend starting with the first above, because that's the simplest. And I think that that is what -melogit- and -meqrlogit- try to fit first (behind the scenes) in order to get starting values.

            You'd probably want to limit the iterations and then take a look at which coefficients or their standard errors are blowing up. Something like this, maybe:
            Code:
            logit NILF_FR i.(anatsi helth funds_n edhigh1) c.(ghpf hgage wealth pincomeg ghmh), iterate(15)

            Comment

            Working...
            X