Hi,
kaplanMeier seems to be misidentifying which survivor functions belong
to
which levels of a factor (when using the formula argument; and I'm using
Splus 2000 release 1). For instance,
> kaplan8c<-kaplanMeier(Surv.censor~Overstory,
data=Surv.factor,subset=Species=="litu")
> kaplan8c
Overstory=gap
Number Observed: 180
Number Censored: 180
Confidence Type: log
Survival Std.Err 95% LCL 95% UCL
(-Inf, 1] 1.000 0.000 1.000 1.000
( 39, 39] 0.631 0.041 0.583 0.684
( 40, 40] 0.631 0.041 0.583 0.684
( 41, 41] 0.617 0.071 0.537 0.708
( 254, 255] 0.188 0.031 0.177 0.200
( 256, 256] 0.169 0.037 0.157 0.182
( 308, 308] 0.128 0.025 0.122 0.134
( 309, 309] 0.128 0.025 0.122 0.134
( 365, 365] 0.107 0.025 0.102 0.113
( 366, 366] 0.103 0.025 0.099 0.109
( 664, 725] 0.056 0.017 0.054 0.057
Overstory=can
Number Observed: 180
Number Censored: 180
Confidence Type: log
Survival Std.Err 95% LCL 95% UCL
(-Inf, 1] 1.000 0.000 1.000 1.000
( 39, 39] 0.711 0.038 0.661 0.766
( 40, 40] 0.711 0.038 0.661 0.766
( 41, 41] 0.614 0.068 0.537 0.701
( 254, 254] 0.433 0.091 0.363 0.518
( 255, 255] 0.349 0.038 0.324 0.376
( 256, 256] 0.278 0.033 0.260 0.297
( 307, 308] 0.278 0.033 0.260 0.297
( 309, 364] 0.247 0.033 0.231 0.263
( 365, 365] 0.247 0.033 0.231 0.263
( 366, 366] 0.186 0.031 0.176 0.198
( 664, 665] 0.172 0.028 0.163 0.182
( 666, 724] 0.172 0.028 0.163 0.182
( 725, 725] 0.138 0.027 0.131 0.145
But now when I do some subsetting of my own (but still still using the same
portion of the data), the survivor function for Gap="gap" above is the same
as the Gap="can" here.
> kaplan8d<-kaplanMeier(Surv.censor[Surv.factor[,3]=="litu",]~ 1,
data=Surv.factor[Surv.factor[,3]=="litu",],subset=Overstory=="can")
> kaplan8d
Number Observed: 180
Number Censored: 180
Confidence Type: log
Survival Std.Err 95% LCL 95% UCL
(-Inf, 1] 1.000 0.000 1.000 1.000
( 39, 39] 0.631 0.041 0.583 0.684
( 40, 40] 0.631 0.041 0.583 0.684
( 41, 41] 0.617 0.071 0.537 0.708
( 254, 255] 0.188 0.031 0.177 0.200
( 256, 256] 0.169 0.037 0.157 0.182
( 308, 308] 0.128 0.025 0.122 0.134
( 309, 309] 0.128 0.025 0.122 0.134
( 365, 365] 0.107 0.025 0.102 0.113
( 366, 366] 0.103 0.025 0.099 0.109
( 664, 725] 0.056 0.017 0.054 0.057
And similarly, subsetting the "gap" portion on my own, produces a survivor
function that corresponds to the "can" portion of the top fit (kaplan8c).
> kaplan8e<-kaplanMeier(Surv.censor[Surv.factor[,3]=="litu" &
Surv.factor[,5]=="gap",]~1,
data=Surv.factor[Surv.factor[,3]=="litu" & Surv.factor[,5]=="gap",])
> kaplan8e
Number Observed: 180
Number Censored: 180
Confidence Type: log
Survival Std.Err 95% LCL 95% UCL
(-Inf, 1] 1.000 0.000 1.000 1.000
( 39, 39] 0.711 0.038 0.661 0.766
( 40, 40] 0.711 0.038 0.661 0.766
( 41, 41] 0.614 0.068 0.537 0.701
( 254, 254] 0.433 0.091 0.363 0.518
( 255, 255] 0.349 0.038 0.324 0.376
( 256, 256] 0.278 0.033 0.260 0.297
( 307, 308] 0.278 0.033 0.260 0.297
( 309, 364] 0.247 0.033 0.231 0.263
( 365, 365] 0.247 0.033 0.231 0.263
( 366, 366] 0.186 0.031 0.176 0.198
( 664, 665] 0.172 0.028 0.163 0.182
( 666, 724] 0.172 0.028 0.163 0.182
( 725, 725] 0.138 0.027 0.131 0.145
I don't know how it behaves when there are more than two levels of a factor.
Brian
-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news
|