Nominal responses

Section of Categorical responses, part of Generalised linear models

Nominal responses

Type Section
Taught in Categorical responses
Part Generalised linear models
Questions using it 1

If the labels can be written in any order, cumulative tails are not available. Start again from the binary logit. With categories 0 and 1, \log\frac{p_1}{p_0}=\beta_0+{\boldsymbol{x}}^\top\boldsymbol{\beta}. With three nominal categories, say rugby =0, cricket =1, netball =2, there are three pairwise log-odds, but only two are free. If cricket is twice as likely as rugby and netball is three times as likely as rugby, then netball is 1.5 times as likely as cricket. In equations, \log\frac{p_2}{p_1} =\log\frac{p_2}{p_0}-\log\frac{p_1}{p_0}, so the third comparison is the difference of the two comparisons against the baseline, and it has the same linear form. Once every category is compared with category 0, every other pair is determined. That is the same bookkeeping as knowing everyone’s mark relative to the lowest mark in the class.

Definition 1 For nominal categories 0,1,\ldots,K-1, the baseline-category logit model is \log\frac{p_k}{p_0}=\beta_{0k}+{\boldsymbol{x}}^\top\boldsymbol{\beta}_k, \qquad k=1,\ldots,K-1. The log-odds of category k against category k' are (\beta_{0k}-\beta_{0k'})+{\boldsymbol{x}}^\top(\boldsymbol{\beta}_k-\boldsymbol{\beta}_{k'}).

Article: Baseline-category logit model →

There are K-1 linear predictors, each with its own intercept and its own slopes. The covariates may be the same. The coefficients are not.

Addiction categories

Main article: Addiction data

A German survey interviewed 712 people about addiction and classified the answers in three categories that we will not put in an order: 0 weak-willed, 1 addiction by disease, 2 both.1 The covariates are sex (female =1), age in years, and an indicator for being a university academic. The first rows look like this: illness 1, female, age 61, not academic; then illness 0, female, 43, not academic; then illness 2, male, 44, not academic.

multinomial(refLevel = 1) takes the lowest level of ill, which is 0, as the reference, even though that level is stored as the number 0. The numbering in the coefficient names is the predictor number, not the illness code.

need <- function(pkg) {
  if (!requireNamespace(pkg, quietly = TRUE)) {
    install.packages(pkg, repos = "https://cloud.r-project.org")
  }
  suppressPackageStartupMessages(library(pkg, character.only = TRUE))
}
need("catdata")
need("VGAM")
data(addiction, package = "catdata")
addiction$ill <- factor(addiction$ill)
summary(vglm(ill ~ gender + age + university,
             family = multinomial(refLevel = 1),
             data = addiction))
               Estimate Std. Error z value
(Intercept):1   -1.1607     0.2654   -4.37
(Intercept):2   -2.0156     0.3076   -6.55
gender:1         0.4366     0.1938    2.25
gender:2         0.2879     0.2208    1.30
age:1            0.0299     0.0062    4.80
age:2            0.0421     0.0068    6.17
university:1     1.6220     0.2535    6.40
university:2     1.0673     0.2891    3.69

Predictor 1 is \log(\hat p_1/\hat p_0), disease versus weak-willed. Predictor 2 is \log(\hat p_2/\hat p_0), both versus weak-willed. Written out, \begin{align*} \log\frac{\hat p_1}{\hat p_0} &=-1.161+0.437\,\mathrm{female}+0.0299\,\mathrm{age}+1.622\,\mathrm{university},\\ \log\frac{\hat p_2}{\hat p_0} &=-2.016+0.288\,\mathrm{female}+0.0421\,\mathrm{age}+1.067\,\mathrm{university}. \end{align*} Reading those coefficients as odds ratios, and the comparison of category 2 against category 1, is the next chapter. The fit itself is the multinomial likelihood with these two linear predictors, dispersion fixed at 1: one independent choice of a single category per person. If a questionnaire let you tick several categories, that 1 would be the wrong dispersion, and this would be the wrong model.

  1. From the proportional-odds intercepts, check that \widehat{\mathrm{P}}(Y\ge 2)>\widehat{\mathrm{P}}(Y\ge 3) at x=0, and say why a reversal would have meant the fit was impossible rather than merely a bad fit.

  2. Show that collapsing mild and severe into one category recovers a single logistic regression from the proportional-odds model, with the same slope \beta.

  3. For the three-category nominal model, derive \log(p_2/p_1) from \log(p_2/p_0) and \log(p_1/p_0), and confirm that the result is still a linear predictor.

Used in

See also

Baseline-category logit model · Proportional-odds model · Ordinal responses · Addiction data · Proportional-hazards model

Glossary and index

Footnotes

  1. The substance itself is named in German in the source paper. What that drug is, and why it would show up among academics, is not part of the model.↩︎