Announcement

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

  • James Park
    started a topic Using same variable for weight and control

    Using same variable for weight and control

    I would like to use the same variable for weight and control like:

    Code:
    sysuse auto
    ivreghdfe price weight (length=trunk) [aw=weight], absorb(rep78)
    But it generates error that says

    Error: cannot use weight variables as dependent variable, regressor or IV in combination with -partial- option.
    Is there any workaround?

  • Carlo Lazzaro
    replied
    James:
    provided that it makes methodological sense, you can create a new variable that mirrors -weight-, but under a different name:
    Code:
    sysuse auto
    clonevar Weight = weight
    ivreghdfe price Weight (length=trunk) [aw=weight], absorb(rep78)

    Leave a comment:

Working...
X