LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (August 2002, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 30 Jul 1996 21:06:42 -0300
Reply-To:     Silvano <silvano@UEL.BR>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Silvano <silvano@UEL.BR>
Subject:      ZIP Models and NLMIXED - correction
Content-Type: multipart/alternative;

Use

fact(y) and not lgamma(y+1).

Silvano.

/****************************************************** * Conjunto de dados usado no artigo de Ridout, Hinde *

* e Demétrio, Biometrics, 57, 219-223 (Março/2001) *

*******************************************************/

Data zip;

input y n;

datalines;

0 182

1 41

2 12

3 2

4 2

5 0

6 0

7 1

;

run;

Proc nlmixed data=zip;

parms p_0 = 0.1 lambda=1;

if y=0 then prob = p_0 +(1-p_0)*exp(-lambda);

else prob = (1-p_0)*exp(-lambda)*(lambda**y)/(fact(y));

loglike = log(prob);

model y ~ general(loglike);

run;

title;


[text/html]


Back to: Top of message | Previous page | Main SAS-L page