[R] Survreg Weibull lambda and p
Ales Ziberna
aleszib at gmail.com
Thu Nov 24 13:12:43 CET 2005
Firstly, I assume that your variable is a numeric one. For seperat values p
and lambda for diferent categories, you should convert it to factor.
However, this has no effect in your case, since you have only 2 categories.
You can have only one p and lambda for a variable with only 2 values. The
model can only evaluate the diference, which is what you got, assuming that
your groups are coded in such a way, that the difference between the codes
is 1.
Best,
Ales Ziberna
----- Original Message -----
From: "Stephen" <szlevine at nana.co.il>
To: <r-help at stat.math.ethz.ch>
Sent: Thursday, November 24, 2005 10:13 AM
Subject: [R] Survreg Weibull lambda and p
> Hi All,
>
>
>
> I have conducted the following survival analysis which appears to be OK
>
> (thanks BRipley for solving my earlier problem).
>
>
>
>> surv.mod1 <- survreg( Surv(timep1, relall6)~randgrpc, data=Dataset,
> dist="weibull", scale = 1)
>
>> summary(surv.mod1)
>
>
>
> Call:
>
> survreg(formula = Surv(timep1, relall6) ~ randgrpc, data = Dataset,
>
> dist = "weibull", scale = 1)
>
> Value Std. Error z p
>
> (Intercept) 7.36 0.259 28.42 1.27e-177
>
> randgrpc -0.59 0.156 -3.80 1.47e-04
>
>
>
> Scale fixed at 1
>
>
>
> Weibull distribution
>
> Loglik(model)= -1268.6 Loglik(intercept only)= -1276
>
> Chisq= 14.72 on 1 degrees of freedom, p= 0.00012
>
> Number of Newton-Raphson Iterations: 5
>
> n= 400
>
>
>
>> version
>
> _
>
> platform i386-pc-mingw32
>
> arch i386
>
> os mingw32
>
> system i386, mingw32
>
> status
>
> major 2
>
> minor 1.1
>
> year 2005
>
> month 06
>
> day 20
>
> language R
>
>>
>
> I emailed this output to a colleague and received an email requesting
> for the 2 groups (randgrpc in the code)
>
> the 'Weibull lambda and p values' in the analysis. I checked the
> mailings for direction but to no avail.
>
> Could someone please provide direction as how to extract the Weibull
> "lambda" and "p" for both randgrpc values?
>
> Many thanks
>
> S.
>
>
> ???? ?"? ???? ????
> http://mail.nana.co.il
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
More information about the R-help
mailing list