From: v0id on
Hi.

I am looking at response time data that, I assume, is a mixture of 3
Weibull distributions. How can I fit such a model to the data using
ML estimation?

Thanks a lot!
Dennis
From: Dale McLerran on
--- On Wed, 2/10/10, v0id <dennis.ruenger(a)GMAIL.COM> wrote:

> From: v0id <dennis.ruenger(a)GMAIL.COM>
> Subject: fitting mixture of Weibull distributions
> To: SAS-L(a)LISTSERV.UGA.EDU
> Date: Wednesday, February 10, 2010, 6:12 PM
> Hi.
>
> I am looking at response time data that, I assume, is a
> mixture of 3
> Weibull distributions. How can I fit such a model to
> the data using
> ML estimation?
>
> Thanks a lot!
> Dennis
>

Dennis,


The NLMIXED procedure can perform this task. There are various
parameterizations of the Weibull distribution. You don't say
what parameterization you want to use. You also don't state
whether the Weibull or mixing distributions are dependent on
some predictor variables. So, all that can be offered here is
a basic outline of NLMIXED procedure code which would fit a
mixture of three Weibull distributions. That said, here is a
shell that should get you started.


proc nlmixed data=mydata;
/* Initialize parameters of Weibull dists and mixing probs */
parms <list and initialize parameters for Weibull dist # 1>
<list and initialize parameters for Weibull dist # 2>
<list and initialize parameters for Weibull dist # 3>
b0_pDist1 b0_pDist2 0;

/* Write out density functions for each of the Weibull dists */
L1 = <density function for Weibull dist 1>;
L2 = <density function for Weibull dist 2>;
L3 = <density function for Weibull dist 3>;

/* Construct mixing probabilities */
exp_b0_pDist1 = exp(b0_pDist1);
exp_b0_pDist2 = exp(b0_pDist2);
denom = 1 + exp_b0_pDist1 + exp_b0_pDist2;
pDist1 = exp_b0_pDist1 / denom;
pDist2 = exp_b0_pDist2 / denom;
pDist3 = 1 / denom;

/* Write mixture distribution density */
Lmix = pDist1*L1 + pDist2*L2 + pDist3*L3;

/* Compute and maximize log-likelihood */
ll = log(Lmix);
model ll ~ general(ll);
run;


Dale

---------------------------------------
Dale McLerran
Fred Hutchinson Cancer Research Center
mailto: dmclerra(a)NO_SPAMfhcrc.org
Ph: (206) 667-2926
Fax: (206) 667-5977
---------------------------------------