The SURVEYPHREG Procedure

Residuals

This section describes the computation of residuals (RESMART, RESDEV, RESSCH, and RESSCO in the OUTPUT statement). See the section Notation and Estimation for definition of notation that is used in this section. The residuals are calculated based on the TIES= option in the MODEL statement.

TIES=BRESLOW

This is the default option. Let

upper S Superscript left-parenthesis r right-parenthesis Baseline left-parenthesis bold-italic beta comma t right-parenthesis equals sigma-summation Underscript upper A Endscripts w Subscript h i j Baseline y Subscript h i j Baseline left-parenthesis t right-parenthesis exp left-parenthesis bold-italic beta prime bold upper Z Subscript h i j Baseline left-parenthesis t right-parenthesis right-parenthesis bold upper Z Subscript h i j Superscript circled-times r Baseline left-parenthesis t right-parenthesis
ModifyingAbove bold upper Z With bar left-parenthesis bold-italic beta comma t right-parenthesis equals StartFraction upper S Superscript left-parenthesis 1 right-parenthesis Baseline left-parenthesis bold-italic beta comma t right-parenthesis Over upper S Superscript left-parenthesis 0 right-parenthesis Baseline left-parenthesis bold-italic beta comma t right-parenthesis EndFraction

where r equals 0 comma 1; and A be the set of indices in the selected sample.

Further let

StartLayout 1st Row 1st Column d normal upper Lamda 0 left-parenthesis bold-italic beta comma t right-parenthesis 2nd Column equals 3rd Column sigma-summation Underscript upper A Endscripts StartFraction w Subscript h i j Baseline d n Subscript h i j Baseline left-parenthesis t right-parenthesis Over upper S Superscript left-parenthesis 0 right-parenthesis Baseline left-parenthesis bold-italic beta comma t right-parenthesis EndFraction 2nd Row 1st Column d upper M Subscript h i j Baseline left-parenthesis bold-italic beta comma t right-parenthesis 2nd Column equals 3rd Column d n Subscript h i j Baseline left-parenthesis t right-parenthesis minus y Subscript h i j Baseline left-parenthesis t right-parenthesis exp left-parenthesis bold-italic beta prime bold upper Z Subscript h i j Baseline left-parenthesis t right-parenthesis right-parenthesis d normal upper Lamda 0 left-parenthesis bold-italic beta comma t right-parenthesis EndLayout

The martingale residual at t is defined as

StartLayout 1st Row 1st Column ModifyingAbove upper M With caret Subscript h i j Baseline left-parenthesis t right-parenthesis 2nd Column equals 3rd Column integral Subscript 0 Superscript t Baseline d upper M Subscript h i j Baseline left-parenthesis ModifyingAbove bold-italic beta With caret comma tau right-parenthesis 2nd Row 1st Column Blank 2nd Column equals 3rd Column n Subscript h i j Baseline left-parenthesis t right-parenthesis minus integral Subscript 0 Superscript t Baseline y Subscript h i j Baseline left-parenthesis tau right-parenthesis exp left-parenthesis ModifyingAbove bold-italic beta With caret prime bold upper Z Subscript h i j Baseline left-parenthesis tau right-parenthesis right-parenthesis d normal upper Lamda 0 left-parenthesis ModifyingAbove bold-italic beta With caret comma tau right-parenthesis EndLayout

Here ModifyingAbove upper M With caret Subscript h i j Baseline left-parenthesis t right-parenthesis estimates the difference over left-parenthesis 0 comma t right-bracket between the observed number of events for the left-parenthesis h comma i comma j right-parenthesis observation unit and a conditional expected number of events. The quantity ModifyingAbove upper M With caret Subscript h i j Baseline identical-to ModifyingAbove upper M With caret Subscript h i j Baseline left-parenthesis normal infinity right-parenthesis is referred to as the martingale residual for the left-parenthesis h comma i comma j right-parenthesis observation unit. For the Cox model with no time-dependent explanatory variables, the martingale residual for the left-parenthesis h comma i comma j right-parenthesis unit with observation time t Subscript left-parenthesis h comma i comma j right-parenthesis and event status normal upper Delta Subscript left-parenthesis h comma i comma j right-parenthesis is

ModifyingAbove upper M With caret Subscript left-parenthesis h comma i comma j right-parenthesis Baseline equals normal upper Delta Subscript left-parenthesis h comma i comma j right-parenthesis Baseline minus normal e Superscript ModifyingAbove bold-italic beta With caret prime bold upper Z Super Subscript left-parenthesis h comma i comma j right-parenthesis Baseline integral Subscript 0 Superscript t Subscript left-parenthesis h comma i comma j right-parenthesis Baseline Baseline d normal upper Lamda 0 left-parenthesis ModifyingAbove bold-italic beta With caret comma s right-parenthesis

The deviance residual upper D Subscript h i j for the left-parenthesis h comma i comma j right-parenthesis observation unit is a transformation of the corresponding martingale residuals,

upper D Subscript h i j Baseline equals sign left-parenthesis ModifyingAbove upper M With caret Subscript h i j Baseline right-parenthesis StartRoot 2 left-bracket minus ModifyingAbove upper M With caret Subscript h i j Baseline minus n Subscript h i j Baseline left-parenthesis normal infinity right-parenthesis log left-parenthesis StartFraction n Subscript h i j Baseline left-parenthesis normal infinity right-parenthesis minus ModifyingAbove upper M With caret Subscript h i j Baseline Over n Subscript h i j Baseline left-parenthesis normal infinity right-parenthesis EndFraction right-parenthesis right-bracket EndRoot

The square root shrinks large negative martingale residuals, while the logarithmic transformation expands martingale residuals that are close to unity. As such, the deviance residuals are more symmetrically distributed around zero than the martingale residuals. For the Cox model, the deviance residual reduces to the form

upper D Subscript h i j Baseline equals sign left-parenthesis ModifyingAbove upper M With caret Subscript h i j Baseline right-parenthesis StartRoot 2 left-bracket minus ModifyingAbove upper M With caret Subscript h i j Baseline minus normal upper Delta Subscript h i j Baseline log left-parenthesis normal upper Delta Subscript h i j Baseline minus ModifyingAbove upper M With caret Subscript h i j Baseline right-parenthesis right-bracket EndRoot

The Schoenfeld (1982) residual vector is calculated on a per-event-time basis. At the kth event time t Subscript h i j comma k of the left-parenthesis h comma i comma j right-parenthesis observation unit, the Schoenfeld residual

ModifyingAbove bold upper U With caret Subscript h i j Baseline left-parenthesis t Subscript h i j comma k Baseline right-parenthesis equals bold upper Z Subscript h i j Baseline left-parenthesis t Subscript h i j comma k Baseline right-parenthesis minus ModifyingAbove bold upper Z With bar left-parenthesis ModifyingAbove bold-italic beta With caret comma t Subscript h i j comma k Baseline right-parenthesis

is the difference between the observed covariate vector for the left-parenthesis h comma i comma j right-parenthesis observation unit and the average of the covariate vectors over the risk set at t Subscript h i j comma k. Under the proportional hazards assumption, the Schoenfeld residuals have the sample path of a random walk; therefore, they are useful in assessing time trend or lack of proportionality.

The score process for the left-parenthesis h comma i comma j right-parenthesis subject at time t is

bold upper L Subscript h i j Baseline left-parenthesis bold-italic beta comma t right-parenthesis equals integral Subscript 0 Superscript t Baseline left-bracket bold upper Z Subscript h i j Baseline left-parenthesis tau right-parenthesis minus ModifyingAbove bold upper Z With bar left-parenthesis bold-italic beta comma tau right-parenthesis right-bracket d upper M Subscript h i j Baseline left-parenthesis bold-italic beta comma tau right-parenthesis

The vector ModifyingAbove bold upper L With caret Subscript h i j Baseline identical-to bold upper L Subscript h i j Baseline left-parenthesis ModifyingAbove bold-italic beta With caret comma normal infinity right-parenthesis is the score residual for the left-parenthesis h comma i comma j right-parenthesis observation unit.

The score residuals are a decomposition of the first partial derivative of the log likelihood. They are useful in assessing the influence of each subject on individual parameter estimates. They also play an important role in the computation of the variance estimators.

TIES=EFRON

For TIES=EFRON, the preceding computation is modified to comply with the Efron partial likelihood. For a given uncensored time t, let delta Subscript h i j Baseline left-parenthesis t right-parenthesis equals 1 if t is an event time for the left-parenthesis h comma i comma j right-parenthesis observation, and 0 otherwise. Let d left-parenthesis t right-parenthesis equals sigma-summation Underscript h i j element-of upper A Endscripts delta Subscript h i j Baseline left-parenthesis t right-parenthesis, which is the number of observation units that have an event at t. For 1 less-than-or-equal-to l less-than-or-equal-to d left-parenthesis t right-parenthesis, let

StartLayout 1st Row 1st Column upper S Superscript left-parenthesis r right-parenthesis Baseline left-parenthesis bold-italic beta comma l comma t right-parenthesis 2nd Column equals 3rd Column sigma-summation Underscript upper A Endscripts w Subscript h i j Baseline y Subscript h i j Baseline left-parenthesis t right-parenthesis StartSet 1 minus StartFraction l minus 1 Over d left-parenthesis t right-parenthesis EndFraction delta Subscript h i j Baseline left-parenthesis t right-parenthesis EndSet exp left-parenthesis bold-italic beta prime bold upper Z Subscript h i j Baseline left-parenthesis t right-parenthesis right-parenthesis bold upper Z Subscript h i j Superscript circled-times r Baseline left-parenthesis t right-parenthesis 2nd Row 1st Column ModifyingAbove bold upper Z With bar left-parenthesis bold-italic beta comma l comma t right-parenthesis 2nd Column equals 3rd Column StartFraction upper S Superscript left-parenthesis 1 right-parenthesis Baseline left-parenthesis bold-italic beta comma l comma t right-parenthesis Over upper S Superscript left-parenthesis 0 right-parenthesis Baseline left-parenthesis bold-italic beta comma l comma t right-parenthesis EndFraction 3rd Row 1st Column d normal upper Lamda 0 left-parenthesis bold-italic beta comma l comma t right-parenthesis 2nd Column equals 3rd Column sigma-summation Underscript upper A Endscripts StartFraction w Subscript h i j Baseline d n Subscript h i j Baseline left-parenthesis t right-parenthesis Over upper S Superscript left-parenthesis 0 right-parenthesis Baseline left-parenthesis bold-italic beta comma l comma t right-parenthesis EndFraction 4th Row 1st Column d upper M Subscript h i j Baseline left-parenthesis bold-italic beta comma l comma t right-parenthesis 2nd Column equals 3rd Column d n Subscript h i j Baseline left-parenthesis t right-parenthesis minus y Subscript h i j Baseline left-parenthesis t right-parenthesis left-parenthesis 1 minus delta Subscript h i j Baseline left-parenthesis t right-parenthesis StartFraction l minus 1 Over d left-parenthesis t right-parenthesis EndFraction right-parenthesis exp left-parenthesis bold-italic beta prime bold upper Z Subscript h i j Baseline left-parenthesis t right-parenthesis right-parenthesis d normal upper Lamda 0 left-parenthesis bold-italic beta comma l comma t right-parenthesis EndLayout

where r equals 0 comma 1, and A are the set of indices in the selected sample.

The martingale residual at t for the left-parenthesis h comma i comma j right-parenthesis observation unit is defined as

StartLayout 1st Row 1st Column ModifyingAbove upper M With caret Subscript h i j Baseline left-parenthesis t right-parenthesis 2nd Column equals 3rd Column integral Subscript 0 Superscript t Baseline StartFraction 1 Over d left-parenthesis tau right-parenthesis EndFraction sigma-summation Underscript l equals 1 Overscript d left-parenthesis tau right-parenthesis Endscripts d upper M Subscript h i j Baseline left-parenthesis ModifyingAbove bold-italic beta With caret comma l comma tau right-parenthesis 2nd Row 1st Column Blank 2nd Column equals 3rd Column n Subscript h i j Baseline left-parenthesis t right-parenthesis minus integral Subscript 0 Superscript t Baseline StartFraction 1 Over d left-parenthesis tau right-parenthesis EndFraction sigma-summation Underscript l equals 1 Overscript d left-parenthesis tau right-parenthesis Endscripts y Subscript h i j Baseline left-parenthesis tau right-parenthesis left-parenthesis 1 minus delta Subscript h i j Baseline left-parenthesis tau right-parenthesis StartFraction l minus 1 Over d left-parenthesis tau right-parenthesis EndFraction right-parenthesis exp left-parenthesis ModifyingAbove bold-italic beta With caret prime bold upper Z Subscript h i j Baseline left-parenthesis tau right-parenthesis right-parenthesis d normal upper Lamda 0 left-parenthesis ModifyingAbove bold-italic beta With caret comma l comma tau right-parenthesis EndLayout

Deviance residuals are computed by using the same transform on the corresponding martingale residuals as in TIES=BRESLOW.

The Schoenfeld residual vector for the left-parenthesis h comma i comma j right-parenthesis observation unit at event time t Subscript h i j comma k is

ModifyingAbove bold upper U With caret Subscript h i j Baseline left-parenthesis t Subscript h i j comma k Baseline right-parenthesis equals bold upper Z Subscript h i j Baseline left-parenthesis t Subscript h i j comma k Baseline right-parenthesis minus StartFraction 1 Over d left-parenthesis t Subscript h i j comma k Baseline right-parenthesis EndFraction sigma-summation Underscript l equals 1 Overscript d left-parenthesis t Subscript h i j comma k Baseline right-parenthesis Endscripts ModifyingAbove bold upper Z With bar left-parenthesis ModifyingAbove bold-italic beta With caret comma l comma t Subscript h i j comma k Baseline right-parenthesis

The score process for the left-parenthesis h comma i comma j right-parenthesis observation unit at time t is

bold upper L Subscript h i j Baseline left-parenthesis bold-italic beta comma t right-parenthesis equals integral Subscript 0 Superscript t Baseline StartFraction 1 Over d left-parenthesis tau right-parenthesis EndFraction sigma-summation Underscript l equals 1 Overscript d left-parenthesis tau right-parenthesis Endscripts left-parenthesis bold upper Z Subscript h i j Baseline left-parenthesis tau right-parenthesis minus ModifyingAbove bold upper Z With bar left-parenthesis bold-italic beta comma l comma tau right-parenthesis right-parenthesis d upper M Subscript h i j Baseline left-parenthesis bold-italic beta comma l comma tau right-parenthesis

The vector ModifyingAbove bold upper L With caret Subscript h i j Baseline identical-to bold upper L Subscript h i j Baseline left-parenthesis ModifyingAbove bold-italic beta With caret comma normal infinity right-parenthesis is the score residual for the left-parenthesis h comma i comma j right-parenthesis observation unit.

Last updated: December 09, 2022