p2s: Primary to Secondary
Description
Using a SEER data frame, this function computes times between primary and secondary cancers. In the resulting data frame, surv and status can be analyzed at the individual level, e.g. using Cox regression.
Usage
p2s(canc,firstS,secondS,yrcut=2010)
Arguments
canc
Data frame produced by mkSEER().
firstS
Vector of names (as Strings) of first cancers you wish to consider.
secondS
Vector of names of second cancers you wish to consider.
yrcut
Only cases diagnosed in yrcut or newer are analyzed. The default of 2010 is the year AML cases after MDS
began to be entered into SEER as second cancers; before they were considered to be part of the first cancer.
This function facilitates studies of the rate at which myeloid neoplasms such as MDS progress to AML.
Value
Data frame with a row for each primary (first cancer) diagnosed on or after yrcut. The surv column holds the
time in months to last follow up or death (status=0), or to the time of diagnosis of the second cancer (status=1).