Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
The LIFETEST Procedure

PROC LIFETEST Statement

PROC LIFETEST < options > ;
The PROC LIFETEST statement invokes the procedure. The following options can appear in the PROC LIFETEST statement and are described in alphabetic order. If no options are requested, PROC LIFETEST computes and displays product-limit estimates of the survival distribution within each stratum and tests the equality of the survival functions across strata.

Task Options Description
Specify Data SetDATA=specifies the input SAS data set
 OUTSURV=names an output data set to contain survival estimates and confidence limits
 OUTTEST=names an output data set to contain rank test statistics forassociation of survival time with covariates limits
Specify ModelALPHA=sets confidence level for survival estimates
 ALPHAQT=sets confidence level for survival time quartiles
 INTERVALS=specifies interval endpoints for life table calculations
 MAXTIME=sets maximum value of time variable for plot
 METHOD=specifies method to compute survivor function
 MISSINGallows missing values to be a stratum level
 NINTERVAL=specifies number of intervals for life table estimates
 SINGULAR=sets tolerance for testing singularity of covariance matrix of rank statistics
 WIDTH=specifies width of intervals for life table estimates
Control outputCENSOREDSYMBOL=defines symbol used for censored observations in plots
 EVENTSYMBOL=specifies symbol used for event observations in plots
 FORMCHAR(1,2,7,9)=defines characters used for line printer plot axes
 LINEPRINTERspecifies that plots are produced by line printer
 NOPRINTsuppresses display of output
 NOTABLEsuppresses display of survival function estimates
 PLOTS=plots survival estimates

ALPHA=value
specifies a number between 0.0001 and 0.9999 that sets the confidence level for the confidence intervals for the survivor function. The confidence level for the interval is 1 - ALPHA. For example, the option ALPHA=0.05 requests a 95% confidence interval for the SDF at each time point. The default value is 0.05.

ALPHAQT=value
specifies a number between 0.0001 and 0.9999 that sets the level for the confidence intervals for the quartiles of the survival time. The confidence level for the interval is 1 - ALPHAQT. For example, the option ALPHAQT=0.05 requests a 95% confidence interval for the quantiles of the survival time. The default value is 0.05.

CENSOREDSYMBOL=name | 'string'
CS=name | 'string'
specifies the symbol value for the censored observations. The value, name or 'string', is the symbol value specification allowed in SAS/GRAPH software. The default is CS=CIRCLE. If you want to omit plotting the censored observations, specify CS=NONE.

DATA=SAS-data-set
names the SAS data set used by PROC LIFETEST. By default, the most recently created SAS data set is used.

EVENTSYMBOL=name | 'string'
ES=name | 'string'
specifies the symbol value for the event observations. The value, name or 'string', is the symbol value specification allowed in SAS/GRAPH software. The default is ES=NONE.

FORMCHAR(1,2,7,9)='string'
defines the characters used for constructing the vertical and horizontal axes of the line printer plots. The string should be four characters. The first and second characters define the vertical and horizontal bars, respectively, which are also used in drawing the steps of the product-limit survival function. The third character defines the tick mark for the axes, and the fourth character defines the lower left corner of the plot. If the FORMCHAR option in PROC LIFETEST is not specified, the value supplied, if any, with the system option FORMCHAR= is used. The default is FORMCHAR(1,2,7,9)='|-+-'. Any character or hexadecimal string can be used to customize the plot appearance. To send the plot output to a printer with the IBM graphics character set (1 or 2) or display it directly on your PC screen, you can use the following hexadecimal representation

   formchar(1,2,7,9)='B3C4C5C0'x

or system option

   formchar='B3C4DAC2BFC3C5B4C0C1D9'x

Refer to the chapter titled "The PLOT Procedure," in the SAS Procedures Guide or the section "System Options" in SAS Language Reference: Dictionary for further information.

INTERVALS=values
specifies a list of interval endpoints for the life table calculations. These endpoints must all be nonnegative numbers. The initial interval is assumed to start at zero whether or not zero is specified in the list. Each interval contains its lower endpoint but does not contain its upper endpoint. When this option is used with the product-limit method, it reduces the number of survival estimates displayed by printing out only the estimates for the smallest time within each specified interval. The INTERVALS= option can be specified in any of the following ways:

list separated by blanks intervals=1 3 5 7
list separated by commas intervals=1,3,5,7
x to y intervals=1 to 7
x to y by z intervals=1 to 7 by 1
combination of the above intervals=1,3 to 5,7

For example, the specification

   intervals=5,10 to 30 by 10

produces the set of intervals

\{ [0,5), [5,10), [10,20), [20,30), [30,\infty) \}

LINEPRINTER
LS
specifies that plots are produced by a line printer instead of by a graphical device.

MAXTIME=value
specifies the maximum value of the time variable allowed on the plots so that outlying points do not determine the scale of the time axis of the plots. This parameter only affects the displayed plots and has no effect on the calculations.

METHOD=type
specifies the method used to compute the survival function estimates. Valid values for type are as follows:

PL | KM
specifies that product-limit (PL) or Kaplan-Meier (KM) estimates are computed.
ACT | LIFE | LT
specifies that life table (or actuarial) estimates are computed.

By default, METHOD=PL.

MISSING
allows missing values for numeric variables and blank values for character variables as valid stratum levels. See the section "Missing Values" for details.

By default, PROC LIFETEST does not use observations with missing values for any stratum variables.

NINTERVAL=value
specifies the number of intervals used to compute the life table estimates of the survivor function. This parameter is overridden by the WIDTH= option or the INTERVALS= option. When you specify the NINTERVAL= option, PROC LIFETEST tries to find an interval that results in round numbers for the endpoints. Consequently, the number of intervals may be different from the number requested. Use the INTERVALS= option to control the interval endpoints. The default is NINTERVAL=10.

NOPRINT
suppresses the display of output. This option is useful when only an output data set is needed. Note that this option temporarily disables the Output Delivery System (ODS). For more information, see Chapter 14, "Using the Output Delivery System."

NOTABLE
suppresses the display of survival function estimates. Only the number of censored and event times, plots, and test results are displayed.

OUTSURV=SAS-data-set
OUTS=SAS-data-set
creates an output SAS data set to contain the estimates of the survival function and corresponding confidence limits for all strata. See the section "Output Data Sets" for more information on the contents of the OUTSURV= SAS data set.

OUTTEST=SAS-data-set
OUTT=SAS-data-set
creates an output SAS data set to contain the overall chi-square test statistic for association with failure time for the variables in the TEST statement, the values of the univariate rank test statistics for each variable in the TEST statement, and the estimated covariance matrix of the univariate rank test statistics. See the section "Output Data Sets" for more information on the contents of the OUTTEST= SAS data set.

PLOTS= ( type <(NAME=name)> <, ..., type <(NAME=name)> > )
creates plots of survival estimates or censored observations, where type is the type of plot and name is a catalog entry name of up to eight characters. Valid values of type are as follows:

CENSORED | C
specifies a plot of censored observations by strata.

SURVIVAL | S
specifies a plot of the estimated SDF versus time.

LOGSURV | LS
specifies a plot of the -log(estimated SDF) versus time.

LOGLOGS | LLS
specifies a plot of the log(-log(estimated SDF) versus log(time).

HAZARD | H
specifies a plot of the estimated hazard function versus time.

PDF | P
specifies a plot of the estimated probability density function versus time.

Parentheses are required in specifying the plots. For example,

   plots = (s)

requests a plot of the estimated survivor function versus time, and

   plots = (s(name=Surv2), h(name=Haz2))

requests a plot of the estimated survivor function versus time and a plot of the estimated hazard function versus time, with Surv2 and Haz2 as their catalog names, respectively.

SINGULAR=value
specifies the tolerance for testing singularity of the covariance matrix for the rank test statistics. The test requires that a pivot for sweeping a covariance matrix be at least this number times a norm of the matrix. The default value is 1E-12.

WIDTH=value
sets the width of the intervals used in the life table calculation of the survival function. This parameter is overridden by the INTERVALS= option.

Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Top
Top

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.