Announcement

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

  • stir command but for clustered/nested data?

    Is there a a command similar to stir in stata, for generating incident rates by group, but after accounting for clustered data? My data is in the following structure; where..
    • Each ID can have infections with multiple strains, and so appears multiple times, once for each strain that its negative for at the baseline so we can assess incidence over followup.
    • ID is the participant identifier and newid is a variable i made which is a infection/strain level identifier
    So infections are nested within people..im just concerned about the incident rates that im getting, can i interpret them as i normally would? Or should i cluster in some way before i can do that? or instead, should i interpret them entirely differently (wording it in terms of infections?)
    The data example:

    Code:
    * Example generated by -dataex-. For more info, type help dataex
    clear
    input double id float newid double(strain_type visit) float(Oral_Date Result incexit)
    10004 1  6  52 18211 0    0
    10004 1  6  53 18386 0  175
    10004 1  6  54 18561 0  350
    10004 1  6  55 18722 0  511
    10004 1  6  56 18904 0  693
    10004 1  6  57 19086 0  875
    10004 1  6  58 19275 0 1064
    10004 1  6  59 19457 0 1246
    10004 1  6  60 19642 0 1431
    10004 1  6  61 19845 0 1634
    10004 1  6 102 21116 0 2905
    10004 1  6 103 21480 0 3269
    10004 2 11  52 18211 0    0
    10004 2 11  53 18386 0  175
    10004 2 11  54 18561 0  350
    10004 2 11  55 18722 0  511
    10004 2 11  56 18904 0  693
    10004 2 11  57 19086 0  875
    10004 2 11  58 19275 0 1064
    10004 2 11  59 19457 0 1246
    10004 2 11  60 19642 0 1431
    10004 2 11  61 19845 0 1634
    10004 2 11 102 21116 0 2905
    10004 2 11 103 21480 0 3269
    10004 3 16  52 18211 0    0
    10004 3 16  53 18386 0  175
    10004 3 16  54 18561 0  350
    10004 3 16  55 18722 0  511
    10004 3 16  56 18904 0  693
    10004 3 16  57 19086 0  875
    10004 3 16  58 19275 0 1064
    10004 3 16  59 19457 0 1246
    10004 3 16  60 19642 0 1431
    10004 3 16  61 19845 0 1634
    10004 3 16 102 21116 0 2905
    10004 3 16 103 21480 0 3269
    10004 4 18  52 18211 0    0
    10004 4 18  53 18386 0  175
    10004 4 18  54 18561 0  350
    10004 4 18  55 18722 0  511
    10004 4 18  56 18904 0  693
    10004 4 18  57 19086 0  875
    10004 4 18  58 19275 0 1064
    10004 4 18  59 19457 0 1246
    10004 4 18  60 19642 0 1431
    10004 4 18  61 19845 0 1634
    10004 4 18 102 21116 0 2905
    10004 4 18 103 21480 0 3269
    end
    format %dN/D/CY Oral_Date
    Thank you for your time!
Working...
X