Re: [R] coxph diagnostics

2013-08-15 Thread John Sorkin
Dr. Therneau, Thank you as always for first writing, and second continuing the Cox model in R (and earlier I believe in SAS). While your comments concerning non-proportional hazards is helpful, it does not fully address the question, What alternatives do I have if I assume proportional

Re: [R] coxph diagnostics

2013-08-14 Thread Andrews, Chris
be close enough to be useful. This is always a problem with goodness-of-fit tests and large datasets. Chris -Original Message- From: Soumitro Dey [mailto:soumitrod...@gmail.com] Sent: Tuesday, August 13, 2013 10:38 AM To: Terry Therneau Cc: r-help@r-project.org Subject: Re: [R] coxph

Re: [R] coxph diagnostics

2013-08-13 Thread Terry Therneau
That's the primary reason for the plot: so that you can look and think. The test statistic is based on whether a LS line fit to the plot has zero slope. For larger data sets you can sometimes have a significant p-value but good agreement with proportional hazards. It's much like an example

Re: [R] coxph diagnostics

2013-08-13 Thread Soumitro Dey
Thank you for your response, Terry. To put the discussion into perspective, my data set is quite large with over 160,000 samples and 38 variables. The event is true for all samples in this dataset. The distribution is zero-inflated (i.e. most events occur at time = 0). The result of the cox.zph

Re: [R] coxph diagnostics

2013-08-12 Thread Soumitro Dey
Thanks to Bert and Göran for your responses. To answer Göran's comment, yes I did plot the Schoenfeld residuals using plot.cox.zph and the lines look horizontal (slope = 0) to me, which makes me think that it contradicts the results of cox.zph. What alternatives do I have if I assume

Re: [R] coxph diagnostics

2013-08-11 Thread Göran Broström
On 08/11/2013 06:14 AM, Soumitro Dey wrote: Hello all, This may be a naive question but since I'm new to R/survival models, I cannot figure it out the problem myself. I have a coxph model for my data and I am trying to test if the proportional hazards assumption holds. Using cox.zph on the

[R] coxph diagnostics

2013-08-10 Thread Soumitro Dey
Hello all, This may be a naive question but since I'm new to R/survival models, I cannot figure it out the problem myself. I have a coxph model for my data and I am trying to test if the proportional hazards assumption holds. Using cox.zph on the model I get a global score: GLOBAL NA 4.20e+02

Re: [R] coxph diagnostics

2013-08-10 Thread Bert Gunter
Although someone on this list may respond, AFAICS this does not seem to be an R question for R-help.I would suggest that you spend some time with a local statistician. A general observation: Statistical model assumptions neither :hold nor don't hold. Quoting George Box, All models are wrong, but

Re: [R] coxph diagnostics plot for shape of hazard function?

2008-11-11 Thread Terry Therneau
Similarly, when I do plot(zph), B(t) is fairly non-constant. This isn't inherently a problem for me. I don't need a hard single number to characterize the shape of the excess risk. However, I'd like to be able to say something qualitative about the shape of the excess risk for the predictor.

[R] coxph diagnostics plot for shape of hazard function?

2008-11-10 Thread Eric Rescorla
Hi, I've been banging my head against the following problem for a while and thought the fine people on r-help might be able to help. I'm using the survival package. I'm studying the survival rate of a population with a preexisting linear-like event rate (there are theoretical reasons to believe