Announcement

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

  • mlogit transition

    Cheers, Sample data here:

    Code:
    clear
    set obs 16
    egen id = seq(), from(1) to(4) block(4)
    egen group = seq(), from(0) to(1) block(8)
    gen job = .
    replace job = 1 in 1
    replace job = 1 in 2
    replace job = 1 in 3
    replace job = 2 in 4
    replace job = 2 in 5
    replace job = 1 in 6
    replace job = 1 in 7
    replace job = 2 in 8
    replace job = 1 in 9
    replace job = 1 in 11
    replace job = 3 in 12
    replace job = 1 in 13
    replace job = 2 in 14
    replace job = 3 in 15
    replace job = 3 in 16

    Basically I want to estimate transition for each group between job categories where job equals to 1 mean not employed, job equals to 2 means interviewing, job equals to 3 means interviewing. So I want to estimate the probability of transition between all the job categories for each group (group 0 and group 1). I read to use mlogit command but I do not know how to make it specify the transition from a particular job group.
    Code:
     
     bysort group: mlogit job

  • #2
    I am not sure I understand; in particular, I don't understand why you are using -mlogit- for transition probabilities; here is a different way to look at it (which might be completely wrong if I have mis-understood you); after reading in the data (thank you for supplying), I added a time variable as follows:
    Code:
    bys id: gen t=_n
    then I -xtset- the data and used -xttrans-:
    Code:
    xtset id t
    bys group: xttrans job
    be sure to look at the help file (or manual entry) for -xttrans- to see if it is what you want

    Comment

    Working...
    X