Announcement

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

  • "initial values not feasible" error with the Probit Heckman model

    I am trying to run a Probit Heckman model following the Stata guideline here, and I keep running into this error message:
    "initial values not feasible
    last estimates not found"

    But I have no issues running the same data with both regress and Heckman commands, and I would appreciate any support on this.

    Here is a data example:
    dataex avg_sentiment opin_leader collective_action economic_demand_complaint count
    output:
    ```
    ----------------------- copy starting from the next line -----------------------
    Code:
    * Example generated by -dataex-. For more info, type help dataex
    clear
    input double avg_sentiment float opin_leader byte(collective_action economic_demand_complaint) int count
    -.6666666666666666 0 0 0 12
    -.6666666666666666 0 1 1 12
    -.6666666666666666 0 0 0 12
    -.6666666666666666 0 0 0 12
    -.6818181818181819 1 0 0 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 0 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.6818181818181819 1 0 1 22
    -.2307692307692307 1 0 1 26
    -.2307692307692307 1 0 0 26
    -.2307692307692307 1 0 0 26
    -.2307692307692307 1 0 1 26
    -.2307692307692307 1 0 0 26
    -.2307692307692307 1 0 0 26
    -.2307692307692307 1 0 1 26
    end
    ------------------ copy up to and including the previous line ------------------
    ```

  • #2
    I have posted this on Stackoverflow as well.
    Last edited by Paolo Maldini; 06 Feb 2023, 09:32.

    Comment


    • #3
      Hi Paolo,
      there isnt really enough information to figure out the problem.
      What the command is telling you is that it couldn't find any combinations for your betas, sigmas and correlations that provided values for the loglikelihood.
      It can be due to many factors including missing data, incorrectly coded data, using strings instead of numerical variables, etc.
      It could also be that the data itself does not lend itself to be modeled under the bivariate normal assumption of Heckman probit.
      F

      Comment


      • #4
        Originally posted by FernandoRios View Post
        Hi Paolo,
        there isnt really enough information to figure out the problem.
        What the command is telling you is that it couldn't find any combinations for your betas, sigmas and correlations that provided values for the loglikelihood.
        It can be due to many factors including missing data, incorrectly coded data, using strings instead of numerical variables, etc.
        It could also be that the data itself does not lend itself to be modeled under the bivariate normal assumption of Heckman probit.
        F
        Thanks and apologies, this is the code that produces the error:
        ```
        heckprob avg_sentiment opin_leader collective_action , select(economic_demand_complaint=opin_leader count)
        ```

        Last edited by Paolo Maldini; 06 Feb 2023, 09:48.

        Comment


        • #5
          heckprobit is for fitting a probit model with sample selection, so you need a binary outcome. For a continuous outcome, see

          Code:
          help heckman

          Comment


          • #6
            Originally posted by Andrew Musau View Post
            heckprobit is for fitting a probit model with sample selection, so you need a binary outcome. For a continuous outcome, see

            Code:
            help heckman
            Thanks Andrew for the support!

            Comment

            Working...
            X