Assume that we have two independent Poisson random variables, $X_1 \sim Poi(\lambda)$ and $X_2 \sim Poi(\lambda\psi)$. My question regards inference about $\psi$, which could be seen as the relative change in Poisson intensity from one time period to another. I especially want the MLE of $\psi$. What I have been trying to do is to get the joint likelihood and marginalize $\lambda$, but I haven't been successful. Instead I always end up with an expression where I would have to know $\lambda$ to be able to get the MLE of $\psi$. Hope someone here has a good idea of how to approach this.
-
$\begingroup$ I can't guarantee that I'll have time to answer this, but are $X_1$ and $X_2$ independent? or do they have some sort of non-independent joint density? $\endgroup$– ClarinetistCommented May 8, 2017 at 18:09
-
$\begingroup$ They are independent, thanks for pointing that out. I've edited my question now so that is clear. $\endgroup$– infstatCommented May 8, 2017 at 18:13
-
$\begingroup$ You have data of $X_1$ and $X_2$? I would think $X_1$ constrains $\lambda$ independent of $X_2$. And $X_2$ can only constrain the $\lambda\psi$ product, with no ability to distinguish the two. What logically would constrain $\psi$ if you have no constraint on $\lambda$? (e.g. if $X_1$ was not observed) $\endgroup$– GeoMatt22Commented May 8, 2017 at 23:46
3 Answers
Let $L(\lambda, \psi)$ be the likelihood function or joint probability density function. (I think you already got it.)
Get $\frac{\partial \log(L(\lambda, \psi))}{\partial \lambda}$ and $\frac{\partial \log(L(\lambda, \psi))}{\partial \psi}$
Set two partial derivatives to zero. Get the solution of $\lambda$ and $ \psi$ in term of $X_1$ and $X_2$. That is your answer.
If the analytical form of the solution is unavailable, you need to use computer software to get the numerical solutions.
A numerical solution to the multiplicative parameter is possible, indeed. Here is a simple solution simulated in R:
> set.seed(4242)
>
> lambda <- runif(1, min = 0, max = 10)
> mu <- runif(1, min = 0, max = 10)
>
> lambda
[1] 9.861143
>
> mu
[1] 3.477161
>
> x <- rpois(n = 1000, lambda = lambda)
> y <- rpois(n = 1000, lambda = mu*lambda)
>
> ll <- function(lambda,mu) {
+ -sum(dpois(x = x, lambda = lambda)*dpois(x = y, lambda = lambda*mu))
+ }
>
> m <- stats4::mle(ll, start = list(lambda = 5 , mu = 5), method = "L-BFGS-B",
+ lower = c(0.001, .001))
> ab <- stats4::coef(m)
> ab
lambda mu
9.183705 3.674439
This is the solution I've reached, based on the answer from a_statistician:
The joint density is given by $$f_{X_1},_{X_2}(x_1, x_2)=e^{-\lambda} e^{-(1+\psi)}\lambda^{x_1+x_2}\psi^{x_2}/x_1!x_2!$$ and the log-likelihood is given by $$l(\lambda, \psi)=-n\lambda-n(1+\psi)+\ln\lambda\sum(x_{i1}+x_{i2})+\ln\psi\sum x_{i2}-\ln(\prod x_{i1}!x_{i2}!).$$ The partial derivative of $l(\lambda, \psi)$ with respect to $\psi$ is $-n+\frac {\sum x_{i2}}\psi$. Setting this equal to zero and solving for $\psi$ yields the MLE of $\psi$: $$\hat\psi=\frac {\sum x_{i2}}n.$$
-
-
$\begingroup$ I use it to denote the sample size of the sample from the joint distribution of $X_1$ and $X_2$. A very reasonable question, since thinking about it, I feel that my solution is maybe not intuitive? $\endgroup$– infstatCommented May 12, 2017 at 8:48
-
$\begingroup$ I do not think there are more than one observation. There are only two numbers $X_1$ and X_2$. $\endgroup$ Commented May 12, 2017 at 12:58
-
$\begingroup$ Okey that might be true, makes me a bit confused. How would you write the likelihood function? $\endgroup$– infstatCommented May 17, 2017 at 9:13
-
$\begingroup$ "How would you write the likelihood function?" You already did it by your first equation. $\endgroup$ Commented May 17, 2017 at 13:56