You previously asked about Weibull in S-PLUS and not about survReg. The
latter fits an accelerated life model, and is documented in the S-PLUS
manuals, V&R and elsewhere.
exp(5.200735) = 181.4, as the coefficient is a mean on - log(T) scale.
1/0.1673101 = 5.98, as `scale' is the standard deviation of the error on
that scale, 1/alpha in the standard Weibull parametrization.
That's all in V&R (2002, pp.360-1).
You can also use fitdistr, as already suggested to you.
On Mon, 17 May 2004, Chris Wilkinson wrote:
> I got some different results from S+ and an independent method (Statistica)
> for the same data (10 uncensored failure times)
>
> > survReg(Surv(ttf) ~ 1, data=data1, dist="weibull")
> Call:
> survReg(formula = Surv(ttf) ~ 1, data = data1, dist = "weibull")
>
> Coefficients:
> (Intercept)
> 5.200735
>
> Scale= 0.1673101
>
> Loglik(model)= -48.8 Loglik(intercept only)= -48.8
> n= 10
>
> whereas Statistica (2-p Weibull) gives scale = 181.4 and shape = 5.98
>
> Now I am confused as to what parameterization is used in survReg().
> Statistica uses exp(-(t/scale)^shape)) as Spencer suggests S+ does but the
> results suggest survReg() uses something different but what?
>
>
> Chris Wilkinson
>
> -----Original Message-----
> From: s-news-owner@lists.biostat.wustl.edu
> [mailto:s-news-owner@lists.biostat.wustl.edu] On Behalf Of Terry Therneau
> Sent: Sunday, May 16, 2004 9:13 PM
> To: kamiltoth@yahoo.com
> Cc: s-news@lists.biostat.wustl.edu
> Subject: Re: [S] Weibull questions
>
>
>
> 2. How to fit a weibull?
> Although survReg and censorreg were designed to allow for censored
> data, they work just fine with ordinary Weibull data.
>
> fit <- survReg(Surv(y) ~ x1 + x2 + ...., data=mydata,
> dist='weibull')
>
>
> Terry Therneau
>
>
> --------------------------------------------------------------------
> This message was distributed by s-news@lists.biostat.wustl.edu. To
> unsubscribe send e-mail to s-news-request@lists.biostat.wustl.edu with the
> BODY of the message: unsubscribe s-news
>
--
Brian D. Ripley, ripley@stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
|