Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Test of person-times in stptime


From   "Wagner, Joseph H" <[email protected]>
To   "STATAList (E-mail)" <[email protected]>
Subject   st: Test of person-times in stptime
Date   Fri, 24 Jan 2003 09:18:41 -0600

I used stptime to calculate person-time for persons who have certain levels
of liver enzymes arranged on a likert scale.  Output below:

. stset censdate, id(patient) fail(died) origin(time consent)

                id:  patient
     failure event:  died ~= 0 & died ~= .
obs. time interval:  (censdate[_n-1], censdate]
 exit on or before:  failure
    t for analysis:  (time-origin)
            origin:  time consent

----------------------------------------------------------------------------
--
     7047  total obs.
       89  obs. end on or before enter()
----------------------------------------------------------------------------
--
     6958  obs. remaining, representing
     6958  subjects
      481  failures in single failure-per-subject data
  7858551  total analysis time at risk, at risk from t =         0
                             earliest observed entry t =         0
                                  last observed exit t =      1929

. 
. tab astlevel if liverscore==0

4 Level AST |      Freq.     Percent        Cum.
------------+-----------------------------------
    AST<0.5 |       1340       36.65       36.65
  AST 0.5<1 |       1726       47.21       83.86
    AST 1<2 |        455       12.45       96.31
     AST 2+ |        135        3.69      100.00
------------+-----------------------------------
      Total |       3656      100.00

. stptime if noliverdx==1, by(astlevel) per(1000) dd(4)

         failure _d:  died
   analysis time _t:  (censdate-origin)
             origin:  time consent
                 id:  patient
(342 missing values generated)

  astlevel |  person-time   failures        rate   [95% Conf. Interval]
-----------+-----------------------------------------------------------
   AST<0.5 |   1531153.0004       55      0.0359     0.0276      0.0468
 AST 0.5<1 |   1973301.9990       94      0.0476     0.0389      0.0583
   AST 1<2 |   518659.9998        36      0.0694     0.0501      0.0962
    AST 2+ |   137030.0007        28      0.2043     0.1411      0.2959
-----------+-----------------------------------------------------------
     total |   4160144.9999      213      0.0512     0.0448      0.0586

I have been asked to do a test between the different person-times.  Is it
possible to do this in STATA?






*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index