Discrete choice model: multinomial logit
Here’s a hypothesis: when people have to make a decision they evaluate all their options and choose the one that scores highest.
choice = argmax(score(option) for option in options)As for that score function, it could be anything. Maybe:
def score(option):
return option.baseline - lam * option.priceThe score of an option goes down with price from some baseline value.
But it’s never that simple. We note that even when faced with exactly the same choices (items and prices) people will not always pick deterministically. They seem flakey.
We hypothesize contextual factors that bias choices at different times. Maybe they were in a hurry that time and needed the closest option, or they heard the ad for it last, or they just felt like something new.
We could try and measure some of these variables and refine our score function, but at some point we’d have to stop. And people will still surprise us. What do we do then? We put on our Stats hats and assume the remaining factors have a benign form. That they affect the score of each option similarly but independently (i.e. IID). For extra convenience we’ll say they are standard Normal Gumbel distributed.
choice = argmax(score(option) + gumbel(0, 1) for option in options)If you do some algebra you’ll find that this hypothesis implies choices are categorically distributed with
\[ p(\mathrm{choice} = i) = \frac{e^{\mathrm{score}_i}}{\sum_j e^{\mathrm{score}_j}} = \operatorname{softmax}(\mathrm{score})_i \]
This is also called a multinomial logit model (a categorical is a multinomial of \(n=1\)) or a softmax regression.