Formula: l_p = sum_i y_i eta_i - sum_i exp(eta_i) - sum_i log(y_i!) - (lambda/2) sum_j beta_j^2, eta_i = beta_0 + x_i'beta
References
Montesinos Lopez, Montesinos Lopez and Crossa (2022), Multivariate Statistical Machine Learning Methods for Genomic Prediction, Springer, doi:10.1007/978-3-030-89010-0. Chapter 7, Sect. 7.5 p. 232. The book fits this by the second-order approximation of the log-likelihood solved as a weighted least squares problem; the intercept is unpenalized. A FIXED iteration count is used rather than a tolerance stop, so both language arms perform identically many updates.
Examples
V <- c(1, 2, 3, 4, 5, 6, 7, 8)
Poispen(V, V)
#> $beta
#> [1] 0.3127190 0.2337641
#>
#> $fitted
#> [1] 1.727168 2.182011 2.756636 3.482586 4.399713 5.558361 7.022135 8.871389
#>
#> $loglik
#> [1] -13.21372
#>
#> $n
#> [1] 8
#>
#> $p
#> [1] 1
#>
#> $method
#> [1] "Penalized Poisson regression, MVSML Sect. 7.5"
#>
#> attr(,"class")
#> [1] "morie_rich_result" "list"
