On 04/22/2012 05:00 AM, r-help-requ...@r-project.org wrote:
I am trying to run Weibull PH model in R.
Assume in the data set I have x1 a continuous variable and x2 a
categorical variable with two classes (0= sick and 1= healthy). I fit the
model in the following way.
Test=survreg(Surv(time,cens)~ x1+x2,dist="weibull")
My questions are
1. Is it Weibull PH model or Weibull AFT model?
Call:
survreg(formula = Surv(time, delta) ~ x1 + x2, data = nn,
dist = "weibull")
Value Std. Error z p
(Intercept) 5.652155 3.54e-02 159.8 0.00e+00
x1 0.492592 1.92e-02 25.7 3.65e-145
x2 -0.000212 5.64e-06 -37.6 0.00e+00
Log(scale) -0.269219 1.57e-02 -17.1 1.24e-65
Scale= 0.764
The Weibull model can be veiwed as either. The cumulative hazard for a
Weibull is t^p, viewed as an AFT model we have (at)^p [multiply time],
viewed as PH we have a(t^p) [multiply the hazard]. The survreg routing
uses the AFT parameterization found in Chapter 2 of Kalbfleisch and
Prentice, "The statistical analysis of failure time data".
For the routine our multiplier "a" above is exp(X beta), for the usual
reason that negative multipliers should be avoided -- it would
correspond to time running backwards. In the above x1 makes time run
faster, x2 time run slower.
Terry T
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.