Announcement

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

  • Person-Specific Indicator

    I have firm-year level data. I want to create person-specific indicators (not firm-specific). However, there are multiple groups (5) that a person can be in. In fact, most people will be in different groups for different years (although each person is only in one firm-year-group at a time). Thus something like this wouldn't be adequate:
    reg yvar xvar i.group1 i.group2 etc.

    Therefore, I think I need to create an indicator variable for each person, something like Person1, Person2, etc. as a dummy variable. However, I have thousands of people in my data. What is the most efficient way to code this? I've experimented with a few loops to no avail.

    Finally, what is the best way to add these variables to a regression command? I don't think this would work based on what I have tried:
    reg yvar xvar person*

    Thanks!

  • #2
    You seem to be dealing with a multi-level crossed-effects model. Search this terms on the Web and you find plenty of information. Not to forget, the Stata Manual under - mixed - command.

    Best regards,

    Marcos

    Comment

    Working...
    X