Intercepts and interactions

Choice Modeling for Marketing in R

Elea McDonnell Feit

Assistant Professor of Marketing, Drexel University

Why no intercepts?

v1 <- alpha * seat1 + beta * price1
v2 <- alpha * seat2 + beta * price2
v3 <- alpha * seat3 + beta * price3
p1 <- exp(v1) / ( exp(v1) + exp(v2) + exp(v3) )
p2 <- exp(v2) / ( exp(v1) + exp(v2) + exp(v3) )
p3 <- exp(v3) / ( exp(v1) + exp(v2) + exp(v3) )
Choice Modeling for Marketing in R

Example with an intercept

intercept <- 5
u1 <- intercept + 1.5
u2 <- intercept +  0 
u3 <- intercept + -1.5  
p1 <- exp(u1) / ( exp(u1) + exp(u2) + exp(u3) )
p2 <- exp(u2) / ( exp(u1) + exp(u2) + exp(u3) )
p3 <- exp(u3) / ( exp(u1) + exp(u2) + exp(u3) )
c(p1, p2, p3)
[1] 0.78559703 0.17529039 0.03911257
Choice Modeling for Marketing in R

Example with an intercept

intercept <- 0
u1 <- intercept + 1.5
u2 <- intercept +  0 
u3 <- intercept + -1.5 
p1 <- exp(u1) / ( exp(u1) + exp(u2) + exp(u3) )
p2 <- exp(u2) / ( exp(u1) + exp(u2) + exp(u3) )
p3 <- exp(u3) / ( exp(u1) + exp(u2) + exp(u3) )
c(p1, p2, p3)
0.78559703 0.17529039 0.03911257
Choice Modeling for Marketing in R

Interactions

u1 <- alpha * seat1 + beta * price1 + gamma * seat1 * price1
u2 <- alpha * seat2 + beta * price2 + gamma * seat2 * price2
u3 <- alpha * seat3 + beta * price3 + gamma * seat3 * price3
Choice Modeling for Marketing in R

Putting interactions into formulas

m4 <- mlogit(choice ~ 0 + seat + trans + convert + price + trans:price, 
             data = sportscar)
m4 <- mlogit(choice ~ 0 + seat + convert + trans * price,
             data = sportscar)
Choice Modeling for Marketing in R

Interpreting interactions

summary(m4)
...
Coefficients :
                         Estimate Std. Error  z-value  Pr(>|z|)    
seat4                  -0.0202794  0.0759464  -0.2670  0.789452    
seat5                   0.4255033  0.0752777   5.6524 1.582e-08 ***
transmanual            -1.1437766  0.0926133 -12.3500 < 2.2e-16 ***
convertyes              0.2621652  0.0821798   3.1901  0.001422 ** 
price                  -0.1908102  0.0086784 -21.9869 < 2.2e-16 ***
transmanual:convertyes -0.1444570  0.1265649  -1.1414  0.253717    
...
Choice Modeling for Marketing in R
summary(sportscar$segment)
basic   fun racer 
 3840  1530   630
m5 <- mlogit(choice ~ 0 + seat + convert + trans + price:segment, 
                      data=sportscar)
summary(m5)
...
Coefficients :
                    Estimate Std. Error  z-value  Pr(>|z|)    
seat4              -0.016206   0.076170  -0.2128  0.831511    
seat5               0.426851   0.075682   5.6401 1.700e-08 ***
convertyes          0.200792   0.062343   3.2207  0.001279 ** 
transmanual        -1.228724   0.066893 -18.3686 < 2.2e-16 ***
price:segmentbasic -0.228245   0.011483 -19.8771 < 2.2e-16 ***
price:segmentfun   -0.133885   0.015677  -8.5405 < 2.2e-16 ***
price:segmentracer -0.132417   0.023398  -5.6594 1.519e-08 ***
...
Choice Modeling for Marketing in R

Let's try some interactions in the chocolate data.

Choice Modeling for Marketing in R

Preparing Video For Download...