# The VGAM package for R

The VGAM package for R fits vector generalized linear and additive models (VGLMs/VGAMs), as well as reduced-rank VGLMs (RR-VGLMs) and quadratic RR-VGLMs (QRR-VGLMs), and can be obtained below. It is a general program for maximum likelihood estimation, and centers on the six S functions vglm(), vgam(), rrvglm(), cqo(), cao() and rcam(). VGAM can fit regression models to the following data types:

• Categorical response
• Nominal
• Multinomial logit model,
• Stereotype model (reduced-rank multinomial logit model),
• Adjacent categories model,
• Ordinal
• Proportional odds model (cumulative logit model),
• Proportional hazards model (cumulative cloglog model),
• Continuation ratio model (sequential logit model),
• Stopping ratio model,
• Others
• Bradley Terry model (with and without ties; intercept only),
• Quantile and expectile regression
• LMS method - e.g., for age-related reference intervals (Box-Cox to normal, Box-Cox to gamma, Yeo-Johnson to normal distributions),
• Asymmetric least squares (expectile regression), e.g., for normal, Poisson, binomial, exponential,
• Asymmetric Laplace distribution,
• Gumbel, GEV, GPD models - for extreme value data,
• Reduced-rank VGLMs
• e.g., RR-multinomial (aka stereotype model), RR-Gaussian, etc.
• Goodman's RC assocation model for two-way tables
• Quadratic RR-VGLMs for constrained quadratic ordination (CQO; formerly called canonical Gaussian ordination or CGO)
• Constrained additive ordination (CAO)
• RR-AR for time series
• Random-effects binomial models
• Beta-binomial model - for teratological/toxicological data,
• Beta-geometric model - for offspring data,
• Bivariate binary responses
• Bivariate logistic model (based on the odds ratio)
• Bivariate probit model (based on the bivariate normal distribution)
• Generalized estimating equations
• Log-linear model for bi-/tri-variate binary responses
• Zero-inflated, zero-altered (hurdle) and positive distributions
• zero-inflated Poisson, binomial, negative binomial, geometric,
• zero-altered Poisson, binomial, negative binomial,
• positive Poisson, binomial, negative binomial, normal,
• Multivariate regression
• Vector additive model
• Seemingly unrelated regressions (SUR),
• Nonlinear regression (via the Gauss-Newton algorithm)
• Michaelis-Menten model,
• Exponential regression (not distributed yet),
• Multivariate nonlinear regression models (not working yet),
• Standard univariate and bivariate distributions  Cauchy (1- and 2-parameter) exponential geometric (and truncated geometric) normal negative binomial Weibull (and truncated Weibull) zeta logarithmic series inverse Gaussian Student t chisquare Pareto (and truncated Pareto) Haight's zeta Erlang Borel-Tanner log-gamma generalized Poisson inverse binomial hyperbolic secant reciprocal inverse Gaussian univariate simplex logistic (1- and 2-parameter) gamma beta (2 parameterizations) lognormal skew normal Leipnik Levy Weibull generalized beta II Singh-Maddala Dagum Fisk beta II Lomax inverse Lomax paralogistic inverse paralogistic Rayleigh Maxwell Nakagami beta-prime McKay's bivariate gamma generalized gamma Freund (1961) bivariate exponential F distribution hypergeometric McCullagh's (1989) distribution Frechet 4-parameter bilogistic Frank's bivariate distribution von Mises Birnbaum-Saunders generalized beta (Libby and Novick, 1982) Zipf distribution sequential binomial double exponential binomial Plackett's bivariate distribution Rice Inverse binomial Kumaraswamy Folded normal Felix Asymmetric Laplace Makeham Perks Lindley Gompertz Gumbel-II
• Nonstandard distributions
• Dirichlet, Dirichlet-multinomial
• Genetic data, - e.g., A-B-AB-O, AB-Ab-aB-ab, blood groups,
• Censored data, - e.g., normal, Tobit model, Gumbel, exponential,
• Robust regression, - e.g., Huber,
• Circular, - e.g., cardioid,
• Not done yet:
• GEE1 for correlated binary data,
• Circular data - e.g., wrapped-normal, wrapped-Cauchy (not distributed yet),
• Spherical data (but none yet),
• Binomial(n,p) - where p is known but n unknown,

Here is the VGAM reference card.pdf (164 KB) (Last updated: 2013-04-29).

For a summary of VGAM click here
Here is a larger summary of VGAM: VGAM.pdf (2.1 MB).

Some data sets have now been placed into another package called VGAMdata. See here
or CRAN.

Users can write their own VGAM family function to solve their own problems. New VGAM family functions are being written all the time.

NOTE: At this stage, vglm(), vgam(), and rrvglm() are pretty well functioning. The functions cqo() (temporary bug) and cao() and rcam() have limited functionality. Many of its methods functions work too. There are only a limited number of help files! There are a number of improvements yet to be added. There are a number of bugs (especially to do with some family functions)---please send in bug reports.

VGAMs are described in Yee and Wild (1996), JRSSB 58: 481-493. If you use this software please quote from this BIBTEX file.

The software, which is free, consists of R, FORTRAN 77 and ANSI C functions. A limited amount of PDF documentation is available. Only a few data sets have been incorporated (R version only), and some of the above family functions aren't distributed yet. Currently VGAM is available at CRAN. It runs under R 2.10.x or higher. VGAM is written in Version 4 of the S language (Chambers, 1998).