Is there anyway that I can perform LASSO with Negative Binomial Regression on R? I am performing a negative binomial regression on my dataset because the data are too dispersed to impose poisson regression. Meanwhile, I am also facing some multicollinearity problem. I already tried using glmnet with family = poisson, but the data is not fitting very well (for both alpha = 0 and alpha = 1).

EDIT: here is variance-covariance table of the negative binomial fit

       8.392729e+18  1.239178e+06  -3.624090e+05  1.896258e+17  -3.702521e+17
       1.239178e+06  1.119052e-04   5.201989e-06 -1.877590e+05  -2.558095e+05
      -3.624090e+05  5.201989e-06   5.179343e-06 -8.021543e+04  -1.436381e+05
       1.896258e+17 -1.877590e+05  -8.021543e+04  2.193290e+17   6.413947e+16
      -3.702521e+17 -2.558095e+05  -1.436381e+05  6.413947e+16   2.142183e+17

  • 1
    $\begingroup$ I think you'll want to take this one to Stack Overflow. $\endgroup$ Dec 31, 2013 at 22:19
  • 1
    $\begingroup$ To be honest, I'm not sure if this question will even be on-topic on SO; you may want to ask on the r-help listserv. $\endgroup$ Dec 31, 2013 at 23:13
  • 1
    $\begingroup$ This question appears to be off-topic because it is about whether a particular analysis can be run in R. $\endgroup$ Dec 31, 2013 at 23:14
  • 4
    $\begingroup$ it's also going to get hammered on SO because it's just a "how can I?" question, rather than a specific programming question ... Can you give a little more context? I would be tempted to do a quasi-Poisson fit (i.e., fit the model as a Poisson lasso, e.g. with the glmnet package, then make a post hoc adjustment to the standard errors of the parameters based on the estimated residual deviance ...) $\endgroup$
    – Ben Bolker
    Dec 31, 2013 at 23:41
  • 1
    $\begingroup$ Have you tried a quasipoisson model then? Based on the very vague description, I think your substantive problem probably has to do with a singularity issue. Show us what the vcov(fit) gives, fit being your glm object. $\endgroup$
    – AdamO
    Dec 31, 2013 at 23:59

1 Answer 1


LASSO and other penalized methods for negative binomial and zero-inflated negative binomial are provided by the mpath package in R, as has been noted on a more recent Cross Validated page. One answer on that page, however, indicates some difficulty in using mpath. A recent publication illustrates an application of the mpath package; a vignette in the R package reproduces the data analysis of that publication.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.