[R] Non-linear Weibull model for aggregated parasite data

Terry Therneau therneau at mayo.edu
Mon Dec 14 15:37:38 CET 2009


" I am trying to fit a non-linear model for a parasite dataset.
Initially, I ...

 The survreg() function will fit a weibull distribution.  It has the
further ability to include censored data, a facility you don't need.
    library(survival)
    fit <- survreg(Surv(coccidiaopg) ~ age + year + sex*season, data=...

One day I should update it so that if there is no censoring then the
Surv() wrapper is not required.  Also, see the examples in the ?survreg
documentation for comments on shape and scale.  This routine uses a
location-scale parameterization which is different than rweibull.

Terry Therneau




More information about the R-help mailing list