# Poisson regression likelihood estimation

Let $Y_1,\dots,Y_n$ independent random variables with $Y_i\sim Poisson(\lambda_i)$. For the likelihood model $$\log(\lambda_i)=\sum_{j=0}^p\beta_jx_ij$$ with $x_i=(x_{i0},\dots,x_{ip})$ where $x_{i0}=1$.

Find

a)Log-likelihood for $\beta$

b)$\frac{\partial{l(\beta)}}{\partial{\beta}}$

c)The Fisher information matrix

First $$\log(\lambda_i)=\sum_{j=0}^p\beta_jx_ij\Rightarrow \lambda_i=e^{\sum_{j=0}^p\beta_jx_ij}$$ The density of Poisson is $$f(y;\lambda_i)=\frac{e^{-e{\sum_{j=0}^p\beta_jx_ij}}e^{\sum_{i=1}^n\sum_{j=0}^p\beta_jx_ij}}{y_i!}$$ then

a) $$L(\beta)=\frac{e^{-\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}}e^{\sum_{i=1}^ny_i\sum_{j=0}^p\beta_jx_ij}}{\prod y_i!}$$ $$l(\beta)\propto -\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}+\sum_{i=1}^ny_i\sum_{j=0}^p\beta_jx_ij$$

b) $$\frac{\partial l(\beta)}{\partial\beta_a}=-\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}x_{ia}+\sum_{i=1}^n y_i x_{ia}$$

c) $$\frac{\partial ^2l(\beta)}{\partial\beta_a\partial\beta_r}=-\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}x_{ia}+\sum_{i=1}^n y_i x_{ia} x_{ir}$$

the Fisher information matrix is $$I(\beta)=-E\Bigg(\frac{\partial ^2l(\beta)}{\partial\beta_a\partial\beta_r}\Bigg)=E\Big(\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}x_{ia}+\sum_{i=1}^n y_i x_{ia} x_{ir}\Big)$$

is that correct or did I made a mistake?

$\frac{\partial l(\beta)}{\partial\beta_a}=-\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}x_{ia}+\sum_{i=1}^n y_i x_{ia}$
$\frac{\partial ^2l(\beta)}{\partial\beta_a\partial\beta_r}=-\sum_{i=1}^n e^{\sum_{j=0}^p\beta_jx_ij}x_{ia}+\sum_{i=1}^n y_i x_{ia} x_{ir}$
In particular, note that the second term in the first expression doesn't contain any $\beta$ terms.