Hi - I have a likelihood function that involves sums of two possions:

L = 
a*dpois(Xi,theta1)*dpois(Yi,theta2)+b*(1-c)*a*dpois(Xi,theta1+theta3)*dpois(Yi,theta2)

where a,b,c,theta1,theta2,theta3 are parameters to be estimated.
(Xi,Yi) are observations. However, Xi and Yi are usually big (>
20000). This causes dpois to returns 0 depending on values of theta1,
theta2 and theta3.

My first question is: is there anyway around this?

My second question is regarding the likelihood function value. Since
dpois returns 0, my log likelihood becomes infinite and causes problem
when optimization. Is there any smart way to avoid this?

Thank you,

rc

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to