What is a hierarchical choice model?

Choice Modeling for Marketing in R

Elea McDonnell Feit

Assistant Professor of Marketing, Drexel University

Heterogeneity in preferences

heterogeneity definition

Choice Modeling for Marketing in R

Hierarchical choice models (random coefficients models)

for (i in 1:n_resp) { 
  beta[i] <- mvrnorm(1, beta_0, Sigma)  # Random normal vector

for (j in 1:n_task[i]) {
X <- X[X$resp == i & X$task == j, ] u <- X %*% beta[i] p[i,] <- exp(u) / sum(exp(u))
}
}
Choice Modeling for Marketing in R

Fitting a hierarchical multinomial logit model

sportscar <- mlogit.data(sportscar, 
                         choice = "choice", 
                         shape = "long", 
                         varying = 5:8, 
                         alt.var = "alt", 
                         id.var = "resp_id")

m7 <- mlogit(choice ~ 0 + seat + trans + convert + price, data = sportscar, rpar = c(price = "n"), panel = TRUE)
Choice Modeling for Marketing in R
summary(m7)
...
Coefficients :
              Estimate Std. Error  z-value  Pr(>|z|)    
seat4       -0.0185815  0.0762964  -0.2435 0.8075843    
seat5        0.4259317  0.0751681   5.6664 1.458e-08 ***
transmanual -1.2206527  0.0650133 -18.7754 < 2.2e-16 ***
convertyes   0.2013760  0.0603982   3.3341 0.0008556 ***
price       -0.1914656  0.0092325 -20.7382 < 2.2e-16 ***
sd.price     0.0230365  0.0327214   0.7040 0.4814209    

Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Log-Likelihood: -1709.8

random coefficients
      Min.    1st Qu.     Median       Mean    3rd Qu. Max.
price -Inf -0.2070035 -0.1914656 -0.1914656 -0.1759277  Inf
...
Choice Modeling for Marketing in R

Distribution of the price coefficient

plot(m7)

price coefficient density

Choice Modeling for Marketing in R

Let's practice!

Choice Modeling for Marketing in R

Preparing Video For Download...