# [R] MNP - discrete choice experiment

Felix Eggers eggers at econ.uni-hamburg.de
Thu Dec 15 15:21:43 CET 2005

```Hello,

I need a little initial help with the MNP package.

I am trying to analyze a discrete choice experiment with the following
settings:
- choice sets consist of 3 alternatives
- choice alternatives are constructed by e.g. two attributes, say brand and
price.
- brand has three levels and price has four levels
- every respondent has to answer 4 different choice sets (drawn randomly or
systematically from the full factorial)
- only the first choice is observed

The data frame ('example') would look like this (brand attribute is effect
coded):

resp	y1	y2	y3	za1M	za1B	za2	zb1M	zb1B	zb2
zc1M	zc1B	zc2
A	1	0	0	1	0	50	0	1	50
-1	-1	50
A	1	0	0	1	0	50	0	1	100
-1	-1	100
A	1	0	0	1	0	50	0	1	150
-1	-1	150
A	0	1	0	1	0	200	0	1	50
-1	-1	200
B	0	0	1	1	0	100	0	1	100
-1	-1	50
...

Notation:
- resp respondent id
- y1, y2, y3 choice indicator for the three alternatives
- za1M and za1B effects coded variables for the brand of the first
alternative, similarly zb1M, zb1B for the second alternative etc.
- za2, zb2, zc2 price level for the first, second and third alternative

I tried the following mnp command for testing:

analysis <- mnp(cbind(y1, y2, y3) ~ 1,
choiceX = list(y1=cbind(za1M, za1B, za2), y2=cbind(zb1M, zb1B, zb2),
y3=cbind(zc1M, zc1B, zc2)),
cXnames = list("M", "B", "price"),
data=example, n.draws=500, burnin=100, thin=3, verbose=TRUE)

My questions are:
1) How can I take into account that every respondent answers 4 choicesets?
Or more generally, how can I obtain individual level estimates?

2) The MNP package description says that the choice specific variables are
recorded relative to the baseline choice. But what if every choice set is
different like in this case?

Any help will be appreciated!

Best regards,
Felix

```