Announcement

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

  • Help with "variables out of order" error

    Hello everyone,

    I am trying to estimate a treatment effect model using the Heckman's sample selection model.
    Here is my code:
    treatreg depressed debt_other healthgl_dum limit_work_10 Inc_10_cpi debt_Inc_V debt_educ_limit grad_cont married work_2010 insured_dum female age black BA_dum rural child_under_2010,treat (debt_educ_dum= Neg_paren_W healthgl_dum97 disable_97 paren_health_dum paren_Inc_dum tuition_ch private for-private)

    When I run the regression it gives the following errors: "variables out of order r(111)"

    I have double checked the order of Heckman selection model and the way I ordered my variables seems to be right.

    Please, can anyone help me understand what is wrong with my code?

    Thank you so much.


  • #2
    The error arises when you specify a variable list and the order does not correspond to the order of variables in your dataset. In your command, the culprit appears to be

    paren_health_dum paren_Inc_dum tuition_ch private for-private)
    where the implication is that the variable "for" does not precede "private". The help for treatreg indicates that it has been superseded by etregress.


    Out-of-date command

    treatreg has been renamed to etregress.

    Comment


    • #3
      Thank you so much for your suggestion. I have renamed the variable and it works. Thank you so much.

      Comment

      Working...
      X