+ Reply to Thread
Results 1 to 1 of 1

Thread: survival analysis - setting up data for Stata stset

  1. #1
    Points: 1,422, Level: 21
    Level completed: 22%, Points required for next Level: 78

    Thanked 0 Times in 0 Posts

    survival analysis - setting up data for Stata stset

    I've the following dataset:

    date0 and date1 are initial and final period
    phase=1 indicates expansion and phase=-1 contraction
    outcome=failure and outcome=0 otherwise
    duration counts the time period for each phase
    var1 and var2 are two variables

    My question is how to write the comand in stata for stset?
    I've tried the following:
    stset date1, failure(outcome=1) time0(date0) origin(time date0)
    but it does not seem correct.
    Also, I want _t to count the time span as the variable ui in my dataset, i.e., not from the beginning of the phase but from the second observation.
    Any help.
    Thanks a lot.
    Attached Files

+ Reply to Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Advertise on Talk Stats